public void testGetRandomColorByLevel(){
  try {
    for (    String level : MaterialPalettes.NON_ACCENT_COLOR_LEVELS) {
      List<Integer> colorList=MaterialPalettes.getColorsByLevel(level);
      Integer randomColor=MaterialPalettes.getRandomColorByLevel(level);
      assertTrue(colorList.contains(randomColor));
    }
  }
 catch (  IllegalAccessException iae) {
    fail();
  }
}

public void testGetRandomColorByLevel ( ) { try { for ( String level : MaterialPalettes . NON_ACCENT_COLOR_LEVELS ) { List < Integer > colorList = MaterialPalettes . getColorsByLevel ( level ) ; Integer randomColor = MaterialPalettes . getRandomColorByLevel ( level ) ; assertTrue ( colorList . contains ( randomColor ) ) ; } } catch ( IllegalAccessException iae ) { fail ( ) ; } }
ensures the color returned has the appropriate level .
