diff --git a/questionGenerator/src/test/java/questionGenerator/QuestionGeneratorTests.java b/questionGenerator/src/test/java/questionGenerator/QuestionGeneratorTests.java index 049caea5..0ea0c41a 100644 --- a/questionGenerator/src/test/java/questionGenerator/QuestionGeneratorTests.java +++ b/questionGenerator/src/test/java/questionGenerator/QuestionGeneratorTests.java @@ -80,6 +80,12 @@ void testGenerateQuestionsEnglish() { } catch (JSONException e) { fail("Exception occurred while parsing JSON: " + e.getMessage()); } + + assertTrue(json.has("language")); + assertEquals(json.get("language"), "en"); + + assertTrue(json.has("type")); + assertEquals(json.get("type"), t.toString()); } } @@ -133,6 +139,12 @@ void testGenerateQuestionsSpanish() { } catch (JSONException e) { fail("Exception occurred while parsing JSON: " + e.getMessage()); } + + assertTrue(json.has("language")); + assertEquals(json.get("language"), "es"); + + assertTrue(json.has("type")); + assertEquals(json.get("type"), t.toString()); } }