Skip to content

Commit

Permalink
impl add test for Float2 type
Browse files Browse the repository at this point in the history
  • Loading branch information
alec1o committed Sep 5, 2023
1 parent 38a6a2a commit 300090d
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion test/ReaderTest.cs
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
using System;
using Byter;
using Xunit;
using Xunit.Abstractions;
namespace ByterTest;

public class ReaderTest
{
private const float FLOAT_X = 1024 * 2;
private const float FLOAT_Y = 1024 * 4;
public ReaderTest() { }

[Fact]
Expand Down Expand Up @@ -256,4 +257,13 @@ public void ReadFloat3()
Assert.Equal(target, result);
Assert.True(reader.Success);
}

[Fact]
public void ImplFloat2()
{
var result = new Float2(FLOAT_X, FLOAT_Y);

Assert.Equal(FLOAT_X, result.X);
Assert.Equal(FLOAT_Y, result.Y);
}
}

0 comments on commit 300090d

Please sign in to comment.