MapzenManager { public static @NonNull MapzenManager instance(@NonNull Context context) { if (instance == null) { instance = new MapzenManager(context.getApplicationContext()); } return instance; } private  MapzenManager(@NonNull Context context); static @NonNull MapzenManager instance(@NonNull Context context); @NonNull String getApiKey(); void setApiKey(@NonNull String apiKey); static @NonNull String getSdkVersion(); void addApiKeyChangeListener(@NonNull ApiKeyChangeListener listener); void removeApiKeyChangeListener(@NonNull ApiKeyChangeListener listener); static final String API_KEY_RES_NAME; static final String API_KEY_RES_TYPE; static final String API_KEY_PARAM_NAME; static final String API_KEY_DEFAULT_VALUE; }
@Test public void shouldNotBeNull() throws Exception { Context context = getMockContext(); Resources resources = new TestResources(); when(context.getResources()).thenReturn(resources); MapzenManager mapzenManager = MapzenManager.instance(context); assertThat(mapzenManager).isNotNull(); }