pub fn new(
        api: ApiDescription<Context>,
        private: Context,
        config_dropshot: &ConfigDropshot,
        log_context: Option<LogContext>,
        log: Logger,
    ) -> TestContext<Context> {
        assert_eq!(
            0,
            config_dropshot.bind_address.port(),
            "test suite only supports binding on port 0 (any available port)"
        );

        /*
         * Set up the server itself.
         */
        let server =
            HttpServerStarter::new(&config_dropshot, api, private, &log)
                .unwrap()
                .start();

        let server_addr = server.local_addr();
        let client_log = log.new(o!("http_client" => "dropshot test suite"));
        let client_testctx = ClientTestContext::new(server_addr, client_log);

        TestContext {
            client_testctx,
            server,
            log,
            log_context,
        }
    }
/**
     * Instantiate a TestContext by creating a new Dropshot server with `api`,
     * `private`, `config_dropshot`, and `log`, and then creating a
     * `ClientTestContext` with whatever address the server wound up bound to.
     *
     * This interfaces requires that `config_dropshot.bind_address.port()` be
     * `0` to allow the server to bind to any available port.  This is necessary
     * in order for it to be used concurrently by many tests.
     */


This interfaces requires that `config_dropshot.bind_address.port()` be
`0` to allow the server to bind to any available port.  This is necessary
in order for it to be used concurrently by many tests.
This interfaces requires that ` config_dropshot . bind_address . port () ` be ` 0 ` to allow the server to bind to any available port . This is necessary in order for it to be used concurrently by many tests .
pub fn new(
        api: ApiDescription<Context>,
        private: Context,
        config_dropshot: &ConfigDropshot,
        log_context: Option<LogContext>,
        log: Logger,
    ) -> TestContext<Context> {
        assert_eq!(
            0,
            config_dropshot.bind_address.port(),
            "test suite only supports binding on port 0 (any available port)"
        );
        /*
         * Set up the server itself.
         */
        let server =
            HttpServerStarter::new(&config_dropshot, api, private, &log)
                .unwrap()
                .start();
        let server_addr = server.local_addr();
        let client_log = log.new(o!("http_client" => "dropshot test suite"));
        let client_testctx = ClientTestContext::new(server_addr, client_log);
        TestContext {
            client_testctx,
            server,
            log,
            log_context,
        }
    }
pub fn new ( api : ApiDescription < Context > , private : Context , config_dropshot : & ConfigDropshot , log_context : Option < LogContext > , log : Logger , ) -> TestContext < Context > { assert_eq ! ( 0 config_dropshot bind_address port ( ) " " ) ; /*
         * Set up the server itself.
         */ let server = HttpServerStarter :: new ( & config_dropshot , api , private , & log ) . unwrap ( ) . start ( ) ; let server_addr = server . local_addr ( ) ; let client_log = log . new ( o ! ( " " " " ) ) ; let client_testctx = ClientTestContext :: new ( server_addr , client_log ) ; TestContext { client_testctx , server , log , log_context , } }
Instantiate a TestContext by creating a new Dropshot server with `api`,
 `private`, `config_dropshot`, and `log`, and then creating a
 `ClientTestContext` with whatever address the server wound up bound to.
Instantiate a TestContext by creating a new Dropshot server with ` api ` ` private ` ` config_dropshot ` and ` log ` and then creating a ` ClientTestContext ` with whatever address the server wound up bound to .
api
ApiDescription<Context>
private
Context
config_dropshot
&ConfigDropshot
log_context
Option<LogContext>
log
Logger
api
ApiDescription<Context>
private
Context
config_dropshot
&ConfigDropshot
log_context
Option<LogContext>
log
Logger