### Question:
Utils { public static synchronized Map<String, String> getMemoryInfo(Context context) { Map<String, String> memoryInfo = new HashMap<String, String>(); memoryInfo.put(Device.AVAILABLE_EXTERNAL_MEMORY_SIZE, String.valueOf(getAvailableExternalMemorySize())); memoryInfo.put(Device.AVAILABLE_INTERNAL_MEMORY_SIZE, String.valueOf(getAvailableInternalMemorySize())); memoryInfo.put(Device.HAS_EXTERNAL_MEMORY, String.valueOf(hasExternalMemory())); memoryInfo.put(Device.TOTAL_EXTERNAL_MEMORY_SIZE, String.valueOf(getTotalExternalMemorySize())); memoryInfo.put(Device.TOTAL_INTERNAL_MEMORY_SIZE, String.valueOf(getTotalInternalMemorySize())); memoryInfo.put(Device.TOTAL_RAM, String.valueOf(getTotalRAM(context))); return memoryInfo; }  static synchronized Map<String, String> getMemoryInfo(Context context); static synchronized boolean hasExternalMemory(); static synchronized long getTotalExternalMemorySize(); static synchronized long getAvailableExternalMemorySize(); static synchronized long getTotalInternalMemorySize(); static synchronized long getAvailableInternalMemorySize(); static synchronized long getTotalRAM(Context context); static synchronized boolean isConnected(Context context); static synchronized boolean isWifiEnabled(Context context); static synchronized String getNetworkType(Context context); static synchronized Map<String, String> getDisplayInfo(Context context); static synchronized String getScreenDensity(Context context); static synchronized int getScreenHeight(Context context); static synchronized int getScreenWidth(Context context); static synchronized String asEmpty(String value); static synchronized String getCountryCode(Context context); static synchronized String getCountryName(Context context); static synchronized Map<String, String> getLocaleInfo(Context context); static synchronized String getLanguageCode(Context context); static synchronized String getLanguageName(Context context); static synchronized String getTimezone(); static synchronized String getVersionName(Context context); static synchronized String getVersionCode(Context context); static synchronized Map<String, String> getPackageInfo(Context context); static synchronized Map<String, String> getBuildInfo(); static synchronized String getUUID(Context context); static final String NETWORK_TYPE_WIFI; static final String NETWORK_TYPE_MOBILE; }### Answer:
@Test public void shouldBeAbleToGetMemoryInfo() { Map<String, String> memoryInfo = Utils.getMemoryInfo(context); assertThat(memoryInfo.get(Device.AVAILABLE_EXTERNAL_MEMORY_SIZE), is(notNullValue())); assertThat(memoryInfo.get(Device.AVAILABLE_INTERNAL_MEMORY_SIZE), is(notNullValue())); assertThat(memoryInfo.get(Device.HAS_EXTERNAL_MEMORY), is(notNullValue())); assertThat(memoryInfo.get(Device.TOTAL_EXTERNAL_MEMORY_SIZE), is(notNullValue())); assertThat(memoryInfo.get(Device.TOTAL_INTERNAL_MEMORY_SIZE), is(notNullValue())); assertThat(memoryInfo.get(Device.TOTAL_RAM), is(notNullValue())); }