### Question:
ScopeEnumConverter { public static ScopeEnum convertToScope(String name) { if (ScopeEnum.contains(name)) { return ScopeEnum.valueOf(name); } return ScopeEnum.zone; }  static ScopeEnum convertToScope(String name);  }### Answer:
@Test public void doTest() { Assert.assertEquals(ScopeEnum.zone, new ScopeEnumConverter().convertToScope("zone")); Assert.assertEquals(ScopeEnum.dataCenter, ScopeEnumConverter.convertToScope("dataCenter")); Assert.assertEquals(ScopeEnum.global, ScopeEnumConverter.convertToScope("global")); Assert.assertEquals(ScopeEnum.zone, ScopeEnumConverter.convertToScope("other value")); }