Java tutorial
//package com.java2s; //License from project: Apache License public class Main { public static void assertEquals(String message, Object val1, Object val2) { if (message != null) { assert val1.equals(val2) : message; } else { assert val1.equals(val2); } } public static void assertEquals(Object val1, Object val2) { assertEquals(null, val1, val2); } }