public virtual void SendLedAnimationCommand(ILedAnimation ledAnimatoin) { int freq = FloatToInt32Converter.Convert(ledAnimatoin.FrequencyInHz); string message = string.Format("{0},{1},{2}", (int)ledAnimatoin.Animation, freq, ledAnimatoin.DurationInSeconds); string command = CommandFormatter.CreateCommand(LedCommand, message); CommandQueue.Enqueue(command); }
private void VerifyFloatConvertsToInt32(float floatTestValue, int expectedInt) { var result = _target.Convert(floatTestValue); result.Should().Be(expectedInt); }