Update test to compile
This commit is contained in:
parent
033d3403cd
commit
a29c662221
|
@ -2,14 +2,15 @@
|
|||
mod test {
|
||||
use ed25519_dalek::SecretKey;
|
||||
use rand::rngs::OsRng;
|
||||
use tapir::acns::tor::authentication::HashedPassword;
|
||||
use tapir::acns::tor::TorProcess;
|
||||
use tapir::connections::service::Service;
|
||||
use tapir::primitives::identity::Identity;
|
||||
use tapir_cwtch::acns::tor::authentication::HashedPassword;
|
||||
use tapir_cwtch::acns::tor::TorProcess;
|
||||
use tapir_cwtch::connections::service::Service;
|
||||
use tapir_cwtch::primitives::identity::Identity;
|
||||
|
||||
use tapir_cwtch::applications::authentication_app::AuthenicationApp;
|
||||
use tapir_cwtch::connections::{Connection, InboundConnection, OutboundConnection};
|
||||
use tapir_cwtch::primitives::transcript::Transcript;
|
||||
|
||||
use tapir::applications::authentication_app::AuthenicationApp;
|
||||
use tapir::connections::{Connection, InboundConnection, OutboundConnection};
|
||||
use tapir::primitives::transcript::Transcript;
|
||||
|
||||
#[test]
|
||||
fn test_simple_setup() {
|
||||
|
@ -32,8 +33,8 @@ mod test {
|
|||
let outbound_service = |mut conn: Connection<OutboundConnection>| {
|
||||
let mut transcript = Transcript::new_transcript("tapir-transcript");
|
||||
let mut auth_app = AuthenicationApp::new(outbound_identity);
|
||||
match auth_app.run_outbound(&mut conn, &mut transcript) {
|
||||
Ok(()) => {
|
||||
match auth_app.run_outbound(conn, &mut transcript) {
|
||||
Ok(_conn) => {
|
||||
println!("Authenticated");
|
||||
}
|
||||
Err(err) => {
|
||||
|
@ -46,7 +47,7 @@ mod test {
|
|||
let inbound_service = |mut conn: Connection<InboundConnection>| {
|
||||
let mut transcript = Transcript::new_transcript("tapir-transcript");
|
||||
let mut auth_app = AuthenicationApp::new(identity);
|
||||
auth_app.run_inbound(&mut conn, &mut transcript);
|
||||
auth_app.run_inbound(conn, &mut transcript);
|
||||
};
|
||||
|
||||
let mut service = service.listen(10029, inbound_service.clone()).unwrap_or_else(|_| panic!());
|
||||
|
|
Loading…
Reference in New Issue