예제 #1
0
파일: UnitTest.cs 프로젝트: tub5/RingApi
        public async Task GetDevicesTest()
        {
            if (!IsSessionActive())
            {
                return;
            }

            var devices = await session.GetRingDevices();

            Assert.IsTrue(devices.Chimes.Count > 0 || devices.Doorbots.Count > 0 || devices.AuthorizedDoorbots.Count > 0 || devices.StickupCams.Count > 0, "No doorbots, stickup cams and/or chimes returned");
        }
예제 #2
0
        public async Task GetDevicesTest()
        {
            var session = new Api.Session(Username, Password);
            await session.Authenticate();

            var devices = await session.GetRingDevices();

            Assert.IsTrue(devices.Chimes.Count > 0 && devices.Doorbots.Count > 0, "No doorbots and/or chimes returned");
        }
예제 #3
0
 public async Task GetDevicesUnauthenticatedTest()
 {
     var session = new Api.Session(Username, Password);
     await session.GetRingDevices();
 }
예제 #4
0
파일: UnitTest.cs 프로젝트: tub5/RingApi
 public async Task GetDevicesUnauthenticatedTest()
 {
     var session = new Api.Session("", "");
     await session.GetRingDevices();
 }