diff options
author | Christian Kollmann <christian.kollmann@a-sit.at> | 2021-02-22 10:43:57 +0100 |
---|---|---|
committer | Christian Kollmann <christian.kollmann@a-sit.at> | 2021-02-22 11:29:08 +0100 |
commit | 84244f4ac1909c20ce36531f110705b24edbad12 (patch) | |
tree | 2e3d9309b1c46ea165c01ff24ad18e63f6ca9b9f /eidas_modules/authmodule-eIDAS-v2/src/test | |
parent | ebd7e620fca36b0b545ebcaaaff8d092e1c42e22 (diff) | |
download | National_eIDAS_Gateway-84244f4ac1909c20ce36531f110705b24edbad12.tar.gz National_eIDAS_Gateway-84244f4ac1909c20ce36531f110705b24edbad12.tar.bz2 National_eIDAS_Gateway-84244f4ac1909c20ce36531f110705b24edbad12.zip |
Rename tasks to clarify functionality
Diffstat (limited to 'eidas_modules/authmodule-eIDAS-v2/src/test')
-rw-r--r-- | eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/tasks/InitialSearchTaskTest.java | 8 | ||||
-rw-r--r-- | eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/tasks/ReceiveOtherLoginMethodGuiResponseTaskTest.java (renamed from eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/tasks/ReceiveLoginMethodGuiResponseTaskTest.java) | 28 |
2 files changed, 16 insertions, 20 deletions
diff --git a/eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/tasks/InitialSearchTaskTest.java b/eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/tasks/InitialSearchTaskTest.java index 95986c49..e0138f62 100644 --- a/eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/tasks/InitialSearchTaskTest.java +++ b/eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/tasks/InitialSearchTaskTest.java @@ -386,7 +386,7 @@ public class InitialSearchTaskTest { .getGenericDataFromSession(Constants.DATA_RESULT_MATCHING_BPK); Assert.assertEquals("Wrong bpk", null, bPk); - Boolean transitionGUI = (Boolean)executionContext.get(Constants.TRANSITION_TO_CREATE_GENERATE_GUI_TASK); + Boolean transitionGUI = (Boolean)executionContext.get(Constants.TRANSITION_TO_GENERATE_OTHER_LOGIN_METHOD_GUI_TASK); Assert.assertEquals("Wrong transition", null, transitionGUI); Boolean transitionErnb = (Boolean)executionContext.get(Constants.TRANSITION_TO_CREATE_NEW_ERNB_ENTRY_TASK); Assert.assertEquals("Wrong transition", true, transitionErnb); @@ -411,7 +411,7 @@ public class InitialSearchTaskTest { pendingReq.getSessionData(AuthProcessDataWrapper.class) .getGenericDataFromSession(Constants.DATA_RESULT_MATCHING_BPK); Assert.assertEquals("Wrong bpk", null, bPk); - Boolean transitionGUI = (Boolean)executionContext.get(Constants.TRANSITION_TO_CREATE_GENERATE_GUI_TASK); + Boolean transitionGUI = (Boolean)executionContext.get(Constants.TRANSITION_TO_GENERATE_OTHER_LOGIN_METHOD_GUI_TASK); Assert.assertEquals("Wrong transition", true, transitionGUI); Boolean transitionErnb = (Boolean)executionContext.get(Constants.TRANSITION_TO_CREATE_NEW_ERNB_ENTRY_TASK); Assert.assertEquals("Wrong transition", null, transitionErnb); @@ -436,7 +436,7 @@ public class InitialSearchTaskTest { pendingReq.getSessionData(AuthProcessDataWrapper.class) .getGenericDataFromSession(Constants.DATA_RESULT_MATCHING_BPK); Assert.assertEquals("Wrong bpk", null, bPk); - Boolean transitionGUI = (Boolean)executionContext.get(Constants.TRANSITION_TO_CREATE_GENERATE_GUI_TASK); + Boolean transitionGUI = (Boolean)executionContext.get(Constants.TRANSITION_TO_GENERATE_OTHER_LOGIN_METHOD_GUI_TASK); Assert.assertEquals("Wrong transition", true, transitionGUI); Boolean transitionErnb = (Boolean)executionContext.get(Constants.TRANSITION_TO_CREATE_NEW_ERNB_ENTRY_TASK); Assert.assertEquals("Wrong transition", null, transitionErnb); @@ -463,7 +463,7 @@ public class InitialSearchTaskTest { pendingReq.getSessionData(AuthProcessDataWrapper.class) .getGenericDataFromSession(Constants.DATA_RESULT_MATCHING_BPK); Assert.assertEquals("Wrong bpk", null, bPk); - Boolean transitionGUI = (Boolean)executionContext.get(Constants.TRANSITION_TO_CREATE_GENERATE_GUI_TASK); + Boolean transitionGUI = (Boolean)executionContext.get(Constants.TRANSITION_TO_GENERATE_OTHER_LOGIN_METHOD_GUI_TASK); Assert.assertEquals("Wrong transition", true, transitionGUI); Boolean transitionErnb = (Boolean)executionContext.get(Constants.TRANSITION_TO_CREATE_NEW_ERNB_ENTRY_TASK); Assert.assertEquals("Wrong transition", null, transitionErnb); diff --git a/eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/tasks/ReceiveLoginMethodGuiResponseTaskTest.java b/eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/tasks/ReceiveOtherLoginMethodGuiResponseTaskTest.java index c6729a03..ae4b5d8c 100644 --- a/eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/tasks/ReceiveLoginMethodGuiResponseTaskTest.java +++ b/eidas_modules/authmodule-eIDAS-v2/src/test/java/at/asitplus/eidas/specific/modules/auth/eidas/v2/test/tasks/ReceiveOtherLoginMethodGuiResponseTaskTest.java @@ -1,13 +1,9 @@ package at.asitplus.eidas.specific.modules.auth.eidas.v2.test.tasks; -import at.asitplus.eidas.specific.connector.MsEidasNodeConstants; import at.asitplus.eidas.specific.modules.auth.eidas.v2.Constants; import at.asitplus.eidas.specific.modules.auth.eidas.v2.dao.SelectedLoginMethod; -import at.asitplus.eidas.specific.modules.auth.eidas.v2.exception.InvalidUserInputException; -import at.asitplus.eidas.specific.modules.auth.eidas.v2.tasks.ReceiveLoginMethodGuiResponseTask; -import at.gv.egiz.eaaf.core.api.data.EaafConstants; +import at.asitplus.eidas.specific.modules.auth.eidas.v2.tasks.ReceiveOtherLoginMethodGuiResponseTask; import at.gv.egiz.eaaf.core.exceptions.TaskExecutionException; -import at.gv.egiz.eaaf.core.impl.idp.controller.tasks.AbstractLocaleAuthServletTask; import at.gv.egiz.eaaf.core.impl.idp.module.test.TestRequestImpl; import at.gv.egiz.eaaf.core.impl.idp.process.ExecutionContextImpl; import org.apache.commons.lang3.RandomStringUtils; @@ -43,29 +39,29 @@ import java.io.UnsupportedEncodingException; }) @ActiveProfiles(profiles = {"deprecatedConfig"}) @WebAppConfiguration -public class ReceiveLoginMethodGuiResponseTaskTest { +public class ReceiveOtherLoginMethodGuiResponseTaskTest { + + @Autowired private ReceiveOtherLoginMethodGuiResponseTask task; - @Autowired private ReceiveLoginMethodGuiResponseTask task; - private ExecutionContextImpl executionContext = new ExecutionContextImpl(); private TestRequestImpl pendingReq; private MockHttpServletRequest httpReq; private MockHttpServletResponse httpResp; - + /** * jUnit class initializer. - * + * */ @BeforeClass public static void classInitializer() { final String current = new java.io.File(".").toURI().toString(); System.setProperty("eidas.ms.configuration", current + "src/test/resources/config/junit_config_1.properties"); - + } - + /** * jUnit test set-up. - * + * */ @Before public void initialize() { @@ -73,14 +69,14 @@ public class ReceiveLoginMethodGuiResponseTaskTest { httpResp = new MockHttpServletResponse(); RequestContextHolder.resetRequestAttributes(); RequestContextHolder.setRequestAttributes(new ServletRequestAttributes(httpReq, httpResp)); - + pendingReq = new TestRequestImpl(); pendingReq.setAuthUrl("https://localhost/ms_connector"); pendingReq.setPendingReqId(RandomStringUtils.randomAlphanumeric(10)); - + LocaleContextHolder.resetLocaleContext(); } - + @Test public void withMobileSignatureSelection() throws TaskExecutionException { test(SelectedLoginMethod.MOBILE_PHONE_SIGNATURE_LOGIN); |