2200: An active access token must be used
[facebook-errors] / src / test / java / de / juplo / facebook / errors / GraphApiExceptionTest.java
index f8bd9aa..9d55e85 100644 (file)
@@ -245,6 +245,17 @@ public class GraphApiExceptionTest
     LOG.debug("{}", e.toString());
   }
 
+  @Test
+  public void testError2200()
+  {
+    String str ="{\"error\":{\"message\":\"An active access token must be used to query information about the current user.\",\"type\":\"OAuthException\",\"code\":2500,\"fbtrace_id\":\"AUmMHJlVYvTbQrBT11Dk104\"}}";
+    byte[] message = str.getBytes();
+    GraphApiException e = GraphApiException.create (status, headers, message);
+
+    assertTrue(e.getClass().equals(ActiveAccessTokenMissingException.class));
+    LOG.debug("{}", e.toString());
+  }
+
   @Test
   public void testUnmappedError()
   {