github.com/lmorg/murex@v0.0.0-20240217211045-e081c89cd4ef/lang/define_getters_test.go (about) 1 package lang 2 3 import ( 4 "testing" 5 6 "github.com/lmorg/murex/lang/types" 7 "github.com/lmorg/murex/test/count" 8 ) 9 10 func TestGetExtType(t *testing.T) { 11 count.Tests(t, 2) 12 13 fileExts = map[string]string{"foo": "bar"} 14 15 if GetExtType("FOO") != "bar" { 16 t.Error("foo != bar") 17 } 18 19 if GetExtType("l;dskjforijf;sdj;oweirnfifunweodijn") != types.Generic { 20 t.Error("Undefined ext != generic") 21 } 22 }