-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathBinaryPrefixTest.cs
More file actions
26 lines (24 loc) · 958 Bytes
/
Copy pathBinaryPrefixTest.cs
File metadata and controls
26 lines (24 loc) · 958 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
using System;
using Codebelt.Extensions.Xunit;
using Xunit;
namespace Codebelt.Unitify
{
public class BinaryPrefixTest : Test
{
public BinaryPrefixTest(ITestOutputHelper output) : base(output)
{
}
[Fact]
public void BinaryPrefix_ShouldVerifyMultiplePrefixConstants()
{
Assert.Equal(BinaryPrefix.Kibi.Multiplier, Math.Pow(2, 10));
Assert.Equal(BinaryPrefix.Mebi.Multiplier, Math.Pow(2, 20));
Assert.Equal(BinaryPrefix.Gibi.Multiplier, Math.Pow(2, 30));
Assert.Equal(BinaryPrefix.Tebi.Multiplier, Math.Pow(2, 40));
Assert.Equal(BinaryPrefix.Pebi.Multiplier, Math.Pow(2, 50));
Assert.Equal(BinaryPrefix.Exbi.Multiplier, Math.Pow(2, 60));
Assert.Equal(BinaryPrefix.Zebi.Multiplier, Math.Pow(2, 70));
Assert.Equal(BinaryPrefix.Yobi.Multiplier, Math.Pow(2, 80));
}
}
}