remove unnecessary TODO comment

`testing.expect` is better than `testing.expectEqual` for behavior
tests. Better for behavior tests to stick to only testing the limited
behavior they are meant to test and avoid functions such as
`expectEqual` that drag in too much of the standard library (in this
case to print helpful diffs about why a value is not equal to another).
This commit is contained in:
Andrew Kelley 2022-03-16 20:35:41 -07:00
parent c8ed813097
commit 80642b5984

View File

@ -85,10 +85,6 @@ fn vector16() !void {
var c = @Vector(4, f16){ 6.25, 6.25, 6.25, 6.25 };
var x = @mulAdd(@Vector(4, f16), a, b, c);
// TODO use `expectEqual` instead once stage2 supports it
// var expected = @Vector(4, f16){ 20, 20, 20, 20 };
// try expectEqual(expected, x);
try expect(x[0] == 20);
try expect(x[1] == 20);
try expect(x[2] == 20);
@ -113,10 +109,6 @@ fn vector32() !void {
var c = @Vector(4, f32){ 6.25, 6.25, 6.25, 6.25 };
var x = @mulAdd(@Vector(4, f32), a, b, c);
// TODO use `expectEqual` instead once stage2 supports it
// var expected = @Vector(4, f32){ 20, 20, 20, 20 };
// try expectEqual(expected, x);
try expect(x[0] == 20);
try expect(x[1] == 20);
try expect(x[2] == 20);
@ -141,10 +133,6 @@ fn vector64() !void {
var c = @Vector(4, f64){ 6.25, 6.25, 6.25, 6.25 };
var x = @mulAdd(@Vector(4, f64), a, b, c);
// TODO use `expectEqual` instead once stage2 supports it
// var expected = @Vector(4, f64){ 20, 20, 20, 20 };
// try expectEqual(expected, x);
try expect(x[0] == 20);
try expect(x[1] == 20);
try expect(x[2] == 20);
@ -190,10 +178,6 @@ fn vector128() !void {
var c = @Vector(4, f128){ 6.25, 6.25, 6.25, 6.25 };
var x = @mulAdd(@Vector(4, f128), a, b, c);
// TODO use `expectEqual` instead once stage2 supports it
// var expected = @Vector(4, f128){ 20, 20, 20, 20 };
// try expectEqual(expected, x);
try expect(x[0] == 20);
try expect(x[1] == 20);
try expect(x[2] == 20);