public void Alarm() { var stream = new TestStream(); using var device = new CyberCard(stream); // enable device.AlarmDisable(); Assert.Equal("C7:0\r", Encoding.ASCII.GetString(stream.ToWrittenArray())); // enable device.AlarmEnable(); Assert.Equal("C7:0\rC7:1\r", Encoding.ASCII.GetString(stream.ToWrittenArray())); }
private void buttonAlarmEnable_Click(object sender, EventArgs e) { Device.AlarmEnable(); }