package com.github.lassana.continuos_audiorecorder;

import android.test.ActivityInstrumentationTestCase2;

import com.github.lassana.continuos_audiorecorder.activity.MainActivity;
import com.jayway.android.robotium.solo.Solo;

/**
 * @author lassana
 * @since 8/25/13
 */
public class MainActivityTest extends ActivityInstrumentationTestCase2<MainActivity> {

    private Solo solo;

    private MainActivity mMainActivity;

    public MainActivityTest() {
        super(MainActivity.class);
    }

    @Override
    protected void setUp() throws Exception {
        super.setUp();

        solo = new Solo(getInstrumentation(), getActivity());

        mMainActivity = getActivity();
    }

    @Override
    protected void tearDown() throws Exception {
        solo.finishOpenedActivities();
    }

    public void testDoubleRecorder() {
        assertNotNull(null);
    }

}

@@ -99,16 +99,46 @@
 stCase2;
+%0Aimport android.widget.Button;
 %0A%0Aimport
@@ -204,16 +204,89 @@
 tivity;%0A
+import com.github.lassana.continuos_audiorecorder.fragment.MainFragment;%0A
 import c
@@ -520,16 +520,154 @@
 ctivity;
+%0A    private MainFragment mMainFragment;%0A    private Button mStartButton;%0A    private Button mPauseButton;%0A    private Button mStopButton;
 %0A%0A    pu
@@ -1083,16 +1083,18 @@
         
+//
 assertNo
@@ -1105,16 +1105,389 @@
 l(null);
+%0A%0A        solo.clickOnButton(%22Start record%22);%0A        solo.sleep(1000);%0A        solo.clickOnButton(%22Pause record%22);%0A        solo.sleep(1000);%0A        solo.clickOnButton(%22Start record%22);%0A        solo.sleep(1000);%0A        solo.clickOnButton(%22Pause record%22);%0A        solo.sleep(1000);%0A        solo.clickOnButton(%22Play record%22);%0A        solo.sleep(1000);%0A        solo.goBack();
 %0A    %7D%0A%0A

Add testDoubleRecorder.