Esempio n. 1
0
        public void GetEapUserDataNullPhoneBookTest()
        {
            RasEntry target = new RasEntry("Test Entry");

            target.GetEapUserData();
        }
Esempio n. 2
0
        public void GetEapUserDataTest()
        {
            byte[] expected = new byte[] { 0, 1 };

            Mock<IRasHelper> mock = new Mock<IRasHelper>();
            RasHelper.Instance = mock.Object;

            mock.Setup(o => o.GetEapUserData(It.IsAny<IntPtr>(), It.IsAny<string>(), It.IsAny<string>())).Returns(expected);

            RasEntry target = new RasEntry("Test Entry");
            target.Owner = new RasPhoneBook();

            byte[] actual = target.GetEapUserData();

            Assert.AreSame(expected, actual);
        }