コード例 #1
0
        public void FillDisplayDeviceIdTest()
        {
            var nativeModel = new DisplayDevice {
                DeviceId = "Id"
            };
            var model = new MonitorDetails.Models.DisplayDevice();

            Helpers.FillDisplayDevice(model, nativeModel);

            Assert.Equal(nativeModel.DeviceId, model.Id);
        }
コード例 #2
0
        public void FillDisplayDeviceStateTest()
        {
            var nativeModel = new DisplayDevice {
                StateFlags = DisplayDeviceState.PrimaryDevice
            };
            var model = new MonitorDetails.Models.DisplayDevice();

            Helpers.FillDisplayDevice(model, nativeModel);

            Assert.Equal(nativeModel.StateFlags, model.State);
        }
コード例 #3
0
        public void FillDisplayDeviceNameTest()
        {
            var nativeModel = new DisplayDevice {
                DeviceName = "Name"
            };
            var model = new MonitorDetails.Models.DisplayDevice();

            Helpers.FillDisplayDevice(model, nativeModel);

            Assert.Equal(nativeModel.DeviceName, model.Name);
        }
コード例 #4
0
        public void FillDisplayDeviceDescriptionTest()
        {
            var nativeModel = new DisplayDevice {
                DeviceString = "String"
            };
            var model = new MonitorDetails.Models.DisplayDevice();

            Helpers.FillDisplayDevice(model, nativeModel);

            Assert.Equal(nativeModel.DeviceString, model.Description);
        }
コード例 #5
0
        public void FillDisplayDeviceKeyTest()
        {
            var nativeModel = new DisplayDevice {
                DeviceKey = "Key"
            };
            var model = new MonitorDetails.Models.DisplayDevice();

            Helpers.FillDisplayDevice(model, nativeModel);

            Assert.Equal(nativeModel.DeviceKey, model.Key);
        }