std: Better handling of type values in expectEqual
parent
81f5e1e667
commit
fe6cc0c3ba
|
@ -53,7 +53,12 @@ pub fn expectEqual(expected: anytype, actual: @TypeOf(expected)) void {
|
||||||
.Void,
|
.Void,
|
||||||
=> return,
|
=> return,
|
||||||
|
|
||||||
.Type,
|
.Type => {
|
||||||
|
if (actual != expected) {
|
||||||
|
std.debug.panic("expected type {}, found type {}", .{ @typeName(expected), @typeName(actual) });
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
.Bool,
|
.Bool,
|
||||||
.Int,
|
.Int,
|
||||||
.Float,
|
.Float,
|
||||||
|
|
Loading…
Reference in New Issue