### Question:
ARGB { public static int toARGB(float a, float r, float g, float b) { int A = ((int) a * 255) << 24; int R = ((int) r * 255) << 16; int G = ((int) g * 255) << 8; int B = ((int) b * 255); return A + R + G + B; }  static float getA(int argb); static int rawA(int argb); static float getR(int argb); static int rawR(int argb); static float getG(int argb); static int rawG(int argb); static float getB(int argb); static int rawB(int argb); static int toARGB(float a, float r, float g, float b); static int toARGB(int a, int r, int g, int b); static float[] toHSVA(int argb);  }### Answer:
@Test public void testToARGB() throws Exception { Assert.assertEquals(0x000000FF, ARGB.toARGB(0f, 0f, 0f, 1f)); Assert.assertEquals(0x0000FF00, ARGB.toARGB(0f, 0f, 1f, 0f)); Assert.assertEquals(0x00FF0000, ARGB.toARGB(0f, 1f, 0f, 0f)); Assert.assertEquals(0xFF000000, ARGB.toARGB(1f, 0f, 0f, 0f)); Assert.assertEquals(0xFFFF0000, ARGB.toARGB(1f, 1f, 0f, 0f)); Assert.assertEquals(0x00FFFF00, ARGB.toARGB(0f, 1f, 1f, 0f)); Assert.assertEquals(0x0000FFFF, ARGB.toARGB(0f, 0f, 1f, 1f)); Assert.assertEquals(0x000000FF, ARGB.toARGB(0, 0, 0, 255)); Assert.assertEquals(0x0000FF00, ARGB.toARGB(0, 0, 255, 0)); Assert.assertEquals(0x00FF0000, ARGB.toARGB(0, 255, 0, 0)); Assert.assertEquals(0xFF000000, ARGB.toARGB(255, 0, 0, 0)); Assert.assertEquals(0xFFFF0000, ARGB.toARGB(255, 255, 0, 0)); Assert.assertEquals(0x00FFFF00, ARGB.toARGB(0, 255, 255, 0)); Assert.assertEquals(0x0000FFFF, ARGB.toARGB(0, 0, 255, 255)); }