improve tests just a bit (#79)

This commit is contained in:
Josh Goebel
2021-04-28 14:45:50 -07:00
committed by GitHub
parent 9b81aec7e4
commit fcea7ba1d5
3 changed files with 13 additions and 1 deletions
+1 -1
View File
@@ -2,4 +2,4 @@ import "os" for Platform
// Can't test for certain values since this test is cross-platform, but we can
// at least make sure it is callable and returns a bool.
System.print(Platform.isPosix is Bool) // expect: true
System.print(Platform.isPosix is Bool) // expect: true
+11
View File
@@ -1,5 +1,16 @@
import "os" for Platform
var platforms = [
"Windows",
"iOS",
"OS X",
"Unknown",
"Linux",
"Unix",
"POSIX"
]
// Can't test for certain values since this test is cross-platform, but we can
// at least make sure it is callable and returns a string.
System.print(Platform.name is String) // expect: true
System.print(platforms.contains(Platform.name)) // expect: true