mirror of
https://github.com/vlang/v.git
synced 2025-09-14 23:12:33 +03:00
tools: sort the match results in the vwhere test, to make it less flaky (#22033)
This commit is contained in:
parent
d7bdb72b48
commit
42d99ba872
1 changed files with 3 additions and 0 deletions
|
@ -190,6 +190,9 @@ fn test_find_in_dir_recursive() {
|
|||
mut fdr := Finder{}
|
||||
fdr.configure_from_arguments(args)
|
||||
fdr.search_for_matches()
|
||||
// the order of matches is not guaranteed.
|
||||
// sorting by line number makes the result more deterministic.
|
||||
fdr.matches.sort(a.line < b.line)
|
||||
dump(fdr.matches)
|
||||
|
||||
assert fdr.matches == [
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue