Mercurial > hg > truffle
comparison graal/com.oracle.graal.jtt/src/com/oracle/graal/jtt/lang/Int_less01.java @ 7282:390448a6b535
converted the JTT tests to use the GraalCompilerTest framework which offers more control over what is compiled and executed
the HP_series and FloatingReads tests have been disabled temporarily
author | Doug Simon <doug.simon@oracle.com> |
---|---|
date | Thu, 20 Dec 2012 14:59:57 +0100 |
parents | e808627bd16f |
children | 64dcb92ee75a |
comparison
equal
deleted
inserted
replaced
7281:e960cda050d7 | 7282:390448a6b535 |
---|---|
22 */ | 22 */ |
23 /* | 23 /* |
24 */ | 24 */ |
25 package com.oracle.graal.jtt.lang; | 25 package com.oracle.graal.jtt.lang; |
26 | 26 |
27 import com.oracle.graal.jtt.*; | |
27 import org.junit.*; | 28 import org.junit.*; |
28 | 29 |
29 @SuppressWarnings("static-method") | 30 public final class Int_less01 extends JTTTest { |
30 public final class Int_less01 { | |
31 | 31 |
32 public static boolean test(int i) { | 32 public static boolean test(int i) { |
33 if (i < 0) { | 33 if (i < 0) { |
34 return true; | 34 return true; |
35 } | 35 } |
36 return false; | 36 return false; |
37 } | 37 } |
38 | 38 |
39 @Test | 39 @Test |
40 public void run0() throws Throwable { | 40 public void run0() throws Throwable { |
41 Assert.assertEquals(true, test(-2147483648)); | 41 runTest("test", -2147483648); |
42 } | 42 } |
43 | 43 |
44 @Test | 44 @Test |
45 public void run1() throws Throwable { | 45 public void run1() throws Throwable { |
46 Assert.assertEquals(true, test(-2)); | 46 runTest("test", -2); |
47 } | 47 } |
48 | 48 |
49 @Test | 49 @Test |
50 public void run2() throws Throwable { | 50 public void run2() throws Throwable { |
51 Assert.assertEquals(true, test(-1)); | 51 runTest("test", -1); |
52 } | 52 } |
53 | 53 |
54 @Test | 54 @Test |
55 public void run3() throws Throwable { | 55 public void run3() throws Throwable { |
56 Assert.assertEquals(false, test(0)); | 56 runTest("test", 0); |
57 } | 57 } |
58 | 58 |
59 @Test | 59 @Test |
60 public void run4() throws Throwable { | 60 public void run4() throws Throwable { |
61 Assert.assertEquals(false, test(1)); | 61 runTest("test", 1); |
62 } | 62 } |
63 | 63 |
64 @Test | 64 @Test |
65 public void run5() throws Throwable { | 65 public void run5() throws Throwable { |
66 Assert.assertEquals(false, test(2)); | 66 runTest("test", 2); |
67 } | 67 } |
68 | 68 |
69 @Test | 69 @Test |
70 public void run6() throws Throwable { | 70 public void run6() throws Throwable { |
71 Assert.assertEquals(false, test(2147483647)); | 71 runTest("test", 2147483647); |
72 } | 72 } |
73 | 73 |
74 } | 74 } |