analyze: fix test case when db.turbo is in $PWD

This commit is contained in:
Motiejus Jakštys 2022-07-11 05:43:59 +03:00
parent 55c63b29da
commit c8fd5a8c72

View File

@ -158,7 +158,7 @@ fn execute(
const testing = std.testing; const testing = std.testing;
test "trivial error: db file" { test "trivial error: db file" {
const args = &[_][*:0]const u8{}; const args = &[_][*:0]const u8{"/does/not/exist.turbo"};
const allocator = testing.allocator; const allocator = testing.allocator;
var stderr = ArrayList(u8).init(allocator); var stderr = ArrayList(u8).init(allocator);
defer stderr.deinit(); defer stderr.deinit();
@ -169,7 +169,7 @@ test "trivial error: db file" {
try testing.expectEqual(@as(u8, 1), exit_code); try testing.expectEqual(@as(u8, 1), exit_code);
try testing.expectEqualStrings( try testing.expectEqualStrings(
stderr.items, stderr.items,
"ERROR: failed to open 'db.turbo': FileNotFound\n", "ERROR: failed to open '/does/not/exist.turbo': FileNotFound\n",
); );
} }