package com.example.todocloud.fragment;

import android.os.Bundle;
import android.support.annotation.Nullable;
import android.support.v4.app.Fragment;
import android.support.v7.widget.DefaultItemAnimator;
import android.support.v7.widget.LinearLayoutManager;
import android.support.v7.widget.RecyclerView;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;

import com.example.todocloud.R;
import com.example.todocloud.adapter.TodoAdapterTest;
import com.example.todocloud.data.Todo;

import java.util.ArrayList;
import java.util.List;

public class TodoListFragmentTest extends Fragment {

  private List<Todo> todosList = new ArrayList<>();
  private TodoAdapterTest todoAdapterTest;
  private RecyclerView recyclerView;

  @Override
  public void onCreate(@Nullable Bundle savedInstanceState) {
    super.onCreate(savedInstanceState);
    setHasOptionsMenu(true);
    todoAdapterTest = new TodoAdapterTest(todosList);
    updateTodoAdapterTest();
  }

  @Nullable
  @Override
  public View onCreateView(LayoutInflater inflater, @Nullable ViewGroup container,
                           @Nullable Bundle savedInstanceState) {
    View view = inflater.inflate(R.layout.todo_list_test, container, false);
    recyclerView = (RecyclerView) view.findViewById(R.id.recycler_view);
    RecyclerView.LayoutManager layoutManager = new LinearLayoutManager(
        getContext().getApplicationContext()
    );
    recyclerView.setLayoutManager(layoutManager);
    recyclerView.setAdapter(todoAdapterTest);
    return view;
  }

  private void updateTodoAdapterTest() {
    Todo todo = new Todo(1, "test", "test", "test", "Test1", false,
        "test", "test", "test", false, 1, false, false);
    todosList.add(todo);

    todo = new Todo(1, "test", "test", "test", "Test2", false,
        "test", "test", "test", false, 1, false, false);
    todosList.add(todo);

    todo = new Todo(1, "test", "test", "test", "Test3", false,
        "test", "test", "test", false, 1, false, false);
    todosList.add(todo);

    todoAdapterTest.notifyDataSetChanged();
  }

}

@@ -518,16 +518,137 @@
 ta.Todo;
+%0Aimport com.example.todocloud.datastorage.DbLoader;%0Aimport com.example.todocloud.datastorage.asynctask.UpdateAdapterTask;
 %0A%0Aimport
@@ -747,16 +747,45 @@
 ment %7B%0A%0A
+  private DbLoader dbLoader;%0A
   privat
@@ -1102,24 +1102,68 @@
 todosList);%0A
+    dbLoader = new DbLoader(getActivity());%0A
     updateTo
@@ -1798,488 +1798,140 @@
     
-Todo todo = new Todo(1, %22test%22, %22test%22, %22test%22, %22Test1%22, false,%0A        %22test%22, %22test%22, %22test%22, false, 1, false, false);%0A    todosList.add(todo);%0A%0A    todo = new Todo(1, %22test%22, %22test%22, %22test%22, %22Test2%22, false,%0A        %22test%22, %22test%22, %22test%22, false, 1, false, false);%0A    todosList.add(todo);%0A%0A    todo = new Todo(1, %22test%22, %22test%22, %22test%22, %22Test3%22, false,%0A        %22test%22, %22test%22, %22test%22, false, 1, false, false);%0A    todosList.add(todo);%0A%0A    todoAdapterTest.notifyDataSetChanged(
+UpdateAdapterTask updateAdapterTask = new UpdateAdapterTask(dbLoader, todoAdapterTest);%0A    updateAdapterTask.execute(getArguments()
 );%0A 

Use real data for TodoAdapterTest