Exemple #1
0
        public void StartTest()
        {
            ForwardedPort target = CreateForwardedPort(); // TODO: Initialize to an appropriate value

            target.Start();
            Assert.Inconclusive("A method that does not return a value cannot be verified.");
        }
Exemple #2
0
        /// <summary>
        /// Thread
        /// </summary>
        /// <param name="o">Parameters</param>
        void jobRun(object o)
        {
            SshClient     ssh  = (SshClient)((object[])o)[0];
            ForwardedPort port = (ForwardedPort)((object[])o)[1];

            ssh.AddForwardedPort(port);
            port.RequestReceived += (sender2, e2) =>
            {
                WriteInfo(e2.OriginatorHost + ":" + e2.OriginatorPort);
            };

            port.Start();

            while (port.IsStarted)
            {
                Thread.Sleep(10);
            }
        }