package com.plnyyanks.tba.apiv2.test;

import com.plnyyanks.tba.apiv2.APIv2Helper;
import com.plnyyanks.tba.apiv2.interfaces.APIv2;

import org.junit.Before;
import org.junit.Test;

/**
 * Created by phil on 5/5/15.
 */
public class APIv2ErrorTest {

    APIv2 api;

    @Before
    public void setupAPIClient(){
        // Do not set the App ID and try and get an error
        api = APIv2Helper.getAPI();
    }

    @Test(expected = Throwable.class)
    public void testApiNoAppId(){
        api.fetchTeam("frc1124", null);
    }
}

@@ -175,16 +175,48 @@
 .Test;%0A%0A
+import retrofit.RetrofitError;%0A%0A
 /**%0A * C
@@ -353,54 +353,90 @@
  // 
-Do not set the App ID and try and get an error
+Make sure no App Id is set so an error is thrown%0A        APIv2Helper.setAppId(%22%22);
 %0A   
@@ -500,17 +500,21 @@
 d = 
-Throwable
+RetrofitError
 .cla
@@ -547,24 +547,91 @@
 iNoAppId()%7B%0A
+        // Since no App Id is set, TBA will return 400 Bad Request%0A
         api.
@@ -648,11 +648,10 @@
 %22frc
-11
 2
+5
 4%22, 

Make sure App Id is not set for test