diff options
Diffstat (limited to 'stdlib/source/test')
-rw-r--r-- | stdlib/source/test/lux/compiler/default/phase/analysis/procedure/common.lux | 36 |
1 files changed, 18 insertions, 18 deletions
diff --git a/stdlib/source/test/lux/compiler/default/phase/analysis/procedure/common.lux b/stdlib/source/test/lux/compiler/default/phase/analysis/procedure/common.lux index 8b5308a5d..a4c4421d2 100644 --- a/stdlib/source/test/lux/compiler/default/phase/analysis/procedure/common.lux +++ b/stdlib/source/test/lux/compiler/default/phase/analysis/procedure/common.lux @@ -91,19 +91,19 @@ paramC (|> r.int (:: @ map code.int))] ($_ seq (test "Can add integers." - (check-success+ "lux int +" (list subjectC paramC) Int)) + (check-success+ "lux int +" (list paramC subjectC) Int)) (test "Can subtract integers." - (check-success+ "lux int -" (list subjectC paramC) Int)) + (check-success+ "lux int -" (list paramC subjectC) Int)) (test "Can multiply integers." - (check-success+ "lux int *" (list subjectC paramC) Int)) + (check-success+ "lux int *" (list paramC subjectC) Int)) (test "Can divide integers." - (check-success+ "lux int /" (list subjectC paramC) Int)) + (check-success+ "lux int /" (list paramC subjectC) Int)) (test "Can calculate remainder of integers." - (check-success+ "lux int %" (list subjectC paramC) Int)) + (check-success+ "lux int %" (list paramC subjectC) Int)) (test "Can test equivalence of integers." - (check-success+ "lux int =" (list subjectC paramC) Bit)) + (check-success+ "lux int =" (list paramC subjectC) Bit)) (test "Can compare integers." - (check-success+ "lux int <" (list subjectC paramC) Bit)) + (check-success+ "lux int <" (list paramC subjectC) Bit)) (test "Can convert integer to fraction." (check-success+ "lux int to-frac" (list subjectC) Frac)) (test "Can convert integer to text." @@ -118,19 +118,19 @@ encodedC (|> (r.unicode 5) (:: @ map code.text))] ($_ seq (test "Can add frac numbers." - (check-success+ "lux frac +" (list subjectC paramC) Frac)) + (check-success+ "lux frac +" (list paramC subjectC) Frac)) (test "Can subtract frac numbers." - (check-success+ "lux frac -" (list subjectC paramC) Frac)) + (check-success+ "lux frac -" (list paramC subjectC) Frac)) (test "Can multiply frac numbers." - (check-success+ "lux frac *" (list subjectC paramC) Frac)) + (check-success+ "lux frac *" (list paramC subjectC) Frac)) (test "Can divide frac numbers." - (check-success+ "lux frac /" (list subjectC paramC) Frac)) + (check-success+ "lux frac /" (list paramC subjectC) Frac)) (test "Can calculate remainder of frac numbers." - (check-success+ "lux frac %" (list subjectC paramC) Frac)) + (check-success+ "lux frac %" (list paramC subjectC) Frac)) (test "Can test equivalence of frac numbers." - (check-success+ "lux frac =" (list subjectC paramC) Bit)) + (check-success+ "lux frac =" (list paramC subjectC) Bit)) (test "Can compare frac numbers." - (check-success+ "lux frac <" (list subjectC paramC) Bit)) + (check-success+ "lux frac <" (list paramC subjectC) Bit)) (test "Can obtain minimum frac number." (check-success+ "lux frac min" (list) Frac)) (test "Can obtain maximum frac number." @@ -155,19 +155,19 @@ toC (|> r.nat (:: @ map code.nat))] ($_ seq (test "Can test text equivalence." - (check-success+ "lux text =" (list subjectC paramC) Bit)) + (check-success+ "lux text =" (list paramC subjectC) Bit)) (test "Compare texts in lexicographical order." - (check-success+ "lux text <" (list subjectC paramC) Bit)) + (check-success+ "lux text <" (list paramC subjectC) Bit)) (test "Can concatenate one text to another." (check-success+ "lux text concat" (list subjectC paramC) Text)) (test "Can find the index of a piece of text inside a larger one that (may) contain it." - (check-success+ "lux text index" (list subjectC paramC fromC) (type (Maybe Nat)))) + (check-success+ "lux text index" (list fromC paramC subjectC) (type (Maybe Nat)))) (test "Can query the size/length of a text." (check-success+ "lux text size" (list subjectC) Nat)) (test "Can obtain the character code of a text at a given index." (check-success+ "lux text char" (list subjectC fromC) Nat)) (test "Can clip a piece of text between 2 indices." - (check-success+ "lux text clip" (list subjectC fromC toC) Text)) + (check-success+ "lux text clip" (list fromC toC subjectC) Text)) )))) (context: "IO procedures" |