correctly generate !=

This commit is contained in:
Dmitry Jemerov
2011-04-07 12:49:31 +02:00
parent 36ae75de34
commit 0af4b3b4c1
3 changed files with 14 additions and 2 deletions
@@ -180,6 +180,11 @@ public class NamespaceGenTest extends LightCodeInsightFixtureTestCase {
binOpTest("fun foo(a: Int, b: Int): Int = a % b", 14, 3, 2);
}
public void testNE() throws Exception {
binOpTest("fun foo(a: Int, b: Int): Int = if (a != b) 1 else 0", 5, 5, 0);
binOpTest("fun foo(a: Int, b: Int): Int = if (a != b) 1 else 0", 5, 3, 1);
}
public void testIfNoElse() throws Exception {
loadFile("ifNoElse.jet");
System.out.println(generateToText());