Skip to content

Commit 6432796

Browse files
committed
Round TotalMilliseconds to match .net behavior
1 parent cdcc533 commit 6432796

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/TaglibSharp.Tests/FileFormats/MpgFormatTest.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@ public void Init ()
2525
public void ReadAudioProperties ()
2626
{
2727
Assert.AreEqual (44100, file.Properties.AudioSampleRate);
28-
Assert.AreEqual (1391, file.Properties.Duration.TotalMilliseconds);
28+
// NOTE, with .net core it keeps the decimal places. So, for now, we round to match .net behavior
29+
Assert.AreEqual (1391, Math.Round (file.Properties.Duration.TotalMilliseconds));
2930
}
3031

3132

0 commit comments

Comments
 (0)