Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- use t::FanLang 'no_plan';
- #no_diff();
- run_tests();
- __DATA__
- === TEST 1: hello world
- --- fan
- say("hello, world");
- --- out
- hello, world
- === TEST 2: simple arithmetic
- --- fan
- say(3+5*2);
- --- out
- 13
- === TEST 3: code block
- --- fan
- {
- print("hi, ");
- say(56.4);
- }
- --- out
- hi, 56.4
- === TEST 4: with unary -
- --- fan
- say(-32 + 1);
- --- out
- -31
- === TEST 5: with unary +
- --- fan
- say(+32 + 1);
- --- out
- 33
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement