예제 #1
0
        public void GitHubQuery_PingAssert_Test()
        {
            //Arrange
            bool result = false;

            //Act
            result = GitHubApiQuery.CheckByPing("127.0.0.1", -1);

            //Assert
            Assert.IsFalse(result);
        }
예제 #2
0
        public void GitHubQuery_PingHostName_Test()
        {
            //Arrange
            bool result = false;

            //Act
            result = GitHubApiQuery.CheckByPing("www.google.com");

            //Assert
            Assert.IsTrue(result);
        }
예제 #3
0
        public void GitHubQuery_PingWEB_Test()
        {
            //Arrange
            bool result = false;

            //Act
            result = GitHubApiQuery.CheckByPing("8.8.8.8", 2000);

            //Assert
            Assert.IsTrue(result);
        }
예제 #4
0
        public void GitHubQuery_PingNoHost_Test()
        {
            //Arrange
            bool result = false;

            //Act
            result = GitHubApiQuery.CheckByPing("");

            //Assert
            Assert.IsFalse(result);
        }
예제 #5
0
        public void GitHubQuery_PingLocal_Test()
        {
            //Arrange
            bool result = false;

            //Act
            result = GitHubApiQuery.CheckByPing("127.0.0.1", 2000);

            //Assert
            Assert.IsTrue(result);
        }