Lines Matching refs:result
22 public static void assertEquals(int expected, int result) {
23 if (expected != result) {
24 throw new Error("Expected: " + expected + ", found: " + result);
28 public static void assertEquals(long expected, long result) {
29 if (expected != result) {
30 throw new Error("Expected: " + expected + ", found: " + result);
34 public static void assertEquals(float expected, float result) {
35 if (expected != result) {
36 throw new Error("Expected: " + expected + ", found: " + result);
40 public static void assertEquals(String expected, float result) {
41 if (!expected.equals(new Float(result).toString())) {
42 throw new Error("Expected: " + expected + ", found: " + result);
46 public static void assertEquals(double expected, double result) {
47 if (expected != result) {
48 throw new Error("Expected: " + expected + ", found: " + result);
52 public static void assertEquals(String expected, double result) {
53 if (!expected.equals(new Double(result).toString())) {
54 throw new Error("Expected: " + expected + ", found: " + result);
58 public static void assertIsNaN(float result) {
59 if (!Float.isNaN(result)) {
60 throw new Error("Expected NaN: " + result);
64 public static void assertIsNaN(double result) {
65 if (!Double.isNaN(result)) {
66 throw new Error("Expected NaN: " + result);