@Test
public void writeUnsynced() throws Exception {

    final String sync = "sync";
    final ContentValues syncValues = new ContentValues();
    syncValues.put(sync, sync);
    when(mSyncStateAdapter.writeUnsynced(mSyncState)).thenReturn(syncValues);
    final ContentValues contentValues = mCategoryDatabaseAdapter.write(mCategory, new DatabaseOperationMetadata());
    assertEquals(NAME, contentValues.getAsString(NAME_KEY));
    assertEquals(CODE, contentValues.getAsString(CODE_KEY));
    assertEquals(sync, contentValues.getAsString(sync));
    assertEquals(CUSTOM_ORDER_ID, (int) contentValues.getAsInteger(CUSTOM_ORDER_ID_KEY));
    assertEquals(CAT_UUID.toString(), contentValues.getAsString(UUID_KEY));
}