diff --git a/gatewayservice/gateway-service.js b/gatewayservice/gateway-service.js index 0bcefac..bab6814 100644 --- a/gatewayservice/gateway-service.js +++ b/gatewayservice/gateway-service.js @@ -21,7 +21,7 @@ const transporter = nodemailer.createTransport({ }); const authServiceUrl = process.env.AUTH_SERVICE_URL || 'http://localhost:8002'; -const userServiceUrl = process.env.USER_SERVICE_URL || 'http://localhost:8011'; +const userServiceUrl = process.env.USER_SERVICE_URL || 'http://localhost:8001'; const questionServiceUrl = process.env.QUESTION_SERVICE_URL || 'http://localhost:8003'; const recordServiceUrl = process.env.RECORD_SERVICE_URL || 'http://localhost:8004'; diff --git a/questionGenerator/src/main/java/Main.java b/questionGenerator/src/main/java/Main.java index 312f993..cd0480f 100644 --- a/questionGenerator/src/main/java/Main.java +++ b/questionGenerator/src/main/java/Main.java @@ -24,7 +24,7 @@ public class Main { QuestionType.SIZE, QuestionType.HEAD_OF_GOVERMENT}; //, QuestionType.VIDEOGAME_DEVELOPER, QuestionType.VIDEOGAME_PUBLISHER, QuestionType.VIDEOGAME_GENRE, QuestionType.VIDEOGAME_COUNTRY}; - private static final int NUMBER_OF_QUESTIONS = 50; + private static final int NUMBER_OF_QUESTIONS = 20; //private static final int NUMBER_OF_QUESTIONS = 75; //private static final int NUMBER_OF_QUESTIONS = 3; //private static final int NUMBER_OF_QUESTIONS = 1; diff --git a/questionGenerator/src/main/java/MainStatic.java b/questionGenerator/src/main/java/MainStatic.java index 42cfba1..f3e3743 100644 --- a/questionGenerator/src/main/java/MainStatic.java +++ b/questionGenerator/src/main/java/MainStatic.java @@ -29,7 +29,6 @@ private static void run(QuestionGenerator qg, QuestionType type, int numberOfQue List questions = qg.generateQuestions(type, numberOfQuestions); for(int i=0; i generateQuestions(QuestionType type, int amount){ try { q = generator.generate(entity); questions.add(q); - System.out.println(questions.size()); } catch(RuntimeException e) { /* * Sometimes not all the parameters for generating can be passed in the query, so this diff --git a/questionGenerator/src/main/java/questionGenerator/generator/answersAreEntites/AbstractAnswersAreEntites.java b/questionGenerator/src/main/java/questionGenerator/generator/answersAreEntites/AbstractAnswersAreEntites.java index 963104e..49cf2ea 100644 --- a/questionGenerator/src/main/java/questionGenerator/generator/answersAreEntites/AbstractAnswersAreEntites.java +++ b/questionGenerator/src/main/java/questionGenerator/generator/answersAreEntites/AbstractAnswersAreEntites.java @@ -47,7 +47,7 @@ private String getAnswer(String id) throws Exception{ public List getWrongAnswers(String rightAnswer) throws Exception { List entites = new ArrayList<>(); try { - entites = EntityGenerator.getEntities(type, getSampleSize(), getPropertyId()); + entites = EntityGenerator.getEntities(type, 20, getPropertyId()); } catch (IOException e) { e.printStackTrace(); } diff --git a/questionGenerator/src/main/java/questionGenerator/question/Question.java b/questionGenerator/src/main/java/questionGenerator/question/Question.java index 7068cbd..7e9a33f 100644 --- a/questionGenerator/src/main/java/questionGenerator/question/Question.java +++ b/questionGenerator/src/main/java/questionGenerator/question/Question.java @@ -9,7 +9,6 @@ public class Question { private String question; private List answers; - private int number = -1; private String language; private QuestionType type; @@ -43,17 +42,12 @@ public void setAnswers(List answers) { public void addRightAnswer(String answer) { answers.add(0, answer); } - - public void setNumber(int number){ - this.number = number; - } public JSONObject getJSON() { JSONObject json = new JSONObject(); json.accumulate("question", question); for(String s : answers) json.accumulate("answers", s); - if(number != -1) json.accumulate("number", number); //Para que los tests pasen json.accumulate("language", language); json.accumulate("type", type); return json; diff --git a/webapp/e2e/steps/competitiveGame.steps.js b/webapp/e2e/steps/competitiveGame.steps.js index ab5ad9e..6e65e98 100644 --- a/webapp/e2e/steps/competitiveGame.steps.js +++ b/webapp/e2e/steps/competitiveGame.steps.js @@ -17,7 +17,7 @@ defineFeature(feature, test => { beforeAll(async () => { browser = await puppeteer.launch({ - headless: "new", + headless: false, slowMo: 40, defaultViewport: { width: 1920, height: 1080 }, args: ['--window-size=1920,1080']