Esempio n. 1
0
        static void Main(string[] args)
        {
            string[] urls = new String[]
            {
                "http://www.mil.be",
                "http://www.mil.be",
                "http://www.mil.be",
                "https://code.i-harness.com/en/q/1d64607",
                "https://blog.angular-university.io/angular-jwt-authentication/",
                "http://www.mil.be",
                "http://www.mil.be",
                "https://code.i-harness.com/en/q/1d64607",
                "http://www.mil.be",
                "https://blog.angular-university.io/angular-jwt-authentication/",
                "http://www.mil.be",
                "http://www.mil.be",
                "https://code.i-harness.com/en/q/1d64607",
                "http://www.mil.be",
                "https://blog.angular-university.io/angular-jwt-authentication/",
                "http://www.mil.be",
                "http://www.mil.be",
                "https://code.i-harness.com/en/q/1d64607",
                "http://www.mil.be",
                "https://blog.angular-university.io/angular-jwt-authentication/",
            };

            manager.Subscribe(ResultsSniff_CollectionChanged);
            manager.Load(urls);
            //  manager.Start();
            manager.Stop();
            Console.WriteLine(manager.ResultsSniffing.Count);

            Console.ReadLine();
        }
        public void SnifferManagerTest()
        {
            string[] urls = new String[]
            {
                "http://www.mil.be",
                "http://www.mil.be",
                "https://code.i-harness.com/en/q/1d64607",
                "http://www.mil.be",
                "https://blog.angular-university.io/angular-jwt-authentication/",
                "http://www.mil.be",
                "http://www.mil.be",
                "https://code.i-harness.com/en/q/1d64607",
                "http://www.mil.be",
                "https://blog.angular-university.io/angular-jwt-authentication/",
                "http://www.mil.be",
                "http://www.mil.be",
                "https://code.i-harness.com/en/q/1d64607",
                "http://www.mil.be",
                "https://blog.angular-university.io/angular-jwt-authentication/",
                "http://www.mil.be",
                "http://www.mil.be",
                "https://code.i-harness.com/en/q/1d64607",
                "http://www.mil.be",
                "https://blog.angular-university.io/angular-jwt-authentication/",
            };
            SnifferManager manager = new SnifferManager();

            manager.Subscribe(ResultsSniff_CollectionChanged);
            manager.Load(urls);
            //      manager.Start();
            manager.Stop();



            Assert.Equal(20, manager.ResultsSniffing.Count);
        }