mirror of
https://github.com/sbrow/envr.git
synced 2026-06-27 18:48:33 -04:00
test: Added missing tests.
This commit is contained in:
@@ -3,6 +3,7 @@ package main
|
||||
import "core:fmt"
|
||||
import "core:os"
|
||||
import "core:path/filepath"
|
||||
import "core:strings"
|
||||
import "core:testing"
|
||||
|
||||
@(test)
|
||||
@@ -85,3 +86,11 @@ test_scan_path_empty_dir :: proc(t: ^testing.T) {
|
||||
testing.expect(t, len(results) == 0, fmt.tprintf("expected 0 results, got %d", len(results)))
|
||||
}
|
||||
|
||||
@(test)
|
||||
test_scan_meets_expectations :: proc(t: ^testing.T) {
|
||||
testing.expect(t, cant_scan({}), "no features should mean can't scan")
|
||||
testing.expect(t, cant_scan({.Git}), "Git alone should mean can't scan")
|
||||
testing.expect(t, !cant_scan({.Fd}), "having Fd should mean can scan")
|
||||
testing.expect(t, !cant_scan({.Fd, .Git}), "both Fd and Git should mean can scan")
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user