From 4f6d91b1200766ab9c0e95f760d30cd1616f88ad Mon Sep 17 00:00:00 2001 From: OZGCloud <ozgcloud@mgm-tp.com> Date: Sun, 26 Feb 2023 21:34:56 +0100 Subject: [PATCH] OZG-3371 implement BayernID Postfach remote service ITCase Sub-task: OZG-3496 --- .../bayernid/BayernIdPostfachClient.java | 6 ++ pluto-server/pom.xml | 11 +- .../ozg/mail/postfach/PostfachMailITCase.java | 6 +- .../BayernIdPostfachServiceITCase.java | 96 ++++++++++++++++++ .../osi/OsiPostfachServiceITCase.java | 4 +- .../application-itcase-bayernid-postfach.yml | 13 +++ .../application-itcase-osi-postfach.yml | 9 ++ .../src/test/resources/application-itcase.yml | 10 -- pluto-server/src/test/resources/bayernid.p12 | Bin 0 -> 6349 bytes .../src/test/resources/bayernid/bsp-nachricht | 1 + .../src/test/resources/bayernid/bsp-quittung | 9 ++ .../bayernid/bsp-quittung-error-in-schema | 9 ++ 12 files changed, 161 insertions(+), 13 deletions(-) create mode 100644 pluto-server/src/test/java/de/itvsh/ozg/mail/postfach/bayernid/BayernIdPostfachServiceITCase.java create mode 100644 pluto-server/src/test/resources/application-itcase-bayernid-postfach.yml create mode 100644 pluto-server/src/test/resources/application-itcase-osi-postfach.yml create mode 100644 pluto-server/src/test/resources/bayernid.p12 create mode 100644 pluto-server/src/test/resources/bayernid/bsp-nachricht create mode 100644 pluto-server/src/test/resources/bayernid/bsp-quittung create mode 100644 pluto-server/src/test/resources/bayernid/bsp-quittung-error-in-schema diff --git a/mail-service/src/main/java/de/itvsh/ozg/mail/postfach/bayernid/BayernIdPostfachClient.java b/mail-service/src/main/java/de/itvsh/ozg/mail/postfach/bayernid/BayernIdPostfachClient.java index 902912fdb..98b800858 100644 --- a/mail-service/src/main/java/de/itvsh/ozg/mail/postfach/bayernid/BayernIdPostfachClient.java +++ b/mail-service/src/main/java/de/itvsh/ozg/mail/postfach/bayernid/BayernIdPostfachClient.java @@ -4,6 +4,7 @@ import javax.xml.bind.JAXBElement; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.oxm.jaxb.Jaxb2Marshaller; +import org.springframework.ws.client.core.WebServiceTemplate; import org.springframework.ws.client.core.support.WebServiceGatewaySupport; import org.springframework.xml.transform.StringResult; import org.springframework.xml.transform.StringSource; @@ -40,4 +41,9 @@ class BayernIdPostfachClient extends WebServiceGatewaySupport { return reply.getValue(); } + + public WebServiceTemplate getWSTemplate() { + return this.getWebServiceTemplate(); + } + } diff --git a/pluto-server/pom.xml b/pluto-server/pom.xml index 47476f7b2..0663b55b1 100644 --- a/pluto-server/pom.xml +++ b/pluto-server/pom.xml @@ -55,8 +55,10 @@ <jsoup.version>1.15.3</jsoup.version> <mongock.version>5.1.4</mongock.version> <testcontainer.version>1.17.3</testcontainer.version> - + <maven-deploy-plugin.version>3.0.0</maven-deploy-plugin.version> + + <spring-ws-test.version>2.0.2.RELEASE</spring-ws-test.version> </properties> <dependencies> @@ -256,6 +258,13 @@ <groupId>org.springframework.security</groupId> <artifactId>spring-security-test</artifactId> </dependency> + <dependency> + <groupId>org.springframework.ws</groupId> + <artifactId>spring-ws-test</artifactId> + <version>${spring-ws-test.version}</version> + <scope>test</scope> + </dependency> + <dependency> <groupId>org.junit.jupiter</groupId> diff --git a/pluto-server/src/test/java/de/itvsh/ozg/mail/postfach/PostfachMailITCase.java b/pluto-server/src/test/java/de/itvsh/ozg/mail/postfach/PostfachMailITCase.java index 7a52b898a..f51a80074 100644 --- a/pluto-server/src/test/java/de/itvsh/ozg/mail/postfach/PostfachMailITCase.java +++ b/pluto-server/src/test/java/de/itvsh/ozg/mail/postfach/PostfachMailITCase.java @@ -34,7 +34,9 @@ import java.time.temporal.ChronoUnit; import java.util.List; import org.assertj.core.api.Assertions; -import org.junit.jupiter.api.*; +import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Nested; +import org.junit.jupiter.api.Test; import org.mockito.ArgumentCaptor; import org.mockito.Captor; import org.mockito.Mock; @@ -45,6 +47,7 @@ import org.springframework.data.mongodb.core.MongoOperations; import org.springframework.http.HttpMethod; import org.springframework.http.MediaType; import org.springframework.security.test.context.support.WithMockUser; +import org.springframework.test.context.ActiveProfiles; import org.springframework.test.web.client.ExpectedCount; import org.springframework.test.web.client.MockRestServiceServer; import org.springframework.web.client.RestTemplate; @@ -65,6 +68,7 @@ import io.grpc.stub.StreamObserver; @SpringBootTest(classes = { PlutoServerApplication.class, OsiPostfachProperties.class }) @DataITCase @WithMockUser +@ActiveProfiles({ "itcase", "with_db", "itcase-osi-postfach" }) class PostfachMailITCase { private static final String TEST_OSI_POSTFACH_URI = "http://localhost/ApiProxy/V1/Message"; diff --git a/pluto-server/src/test/java/de/itvsh/ozg/mail/postfach/bayernid/BayernIdPostfachServiceITCase.java b/pluto-server/src/test/java/de/itvsh/ozg/mail/postfach/bayernid/BayernIdPostfachServiceITCase.java new file mode 100644 index 000000000..c41fab7dc --- /dev/null +++ b/pluto-server/src/test/java/de/itvsh/ozg/mail/postfach/bayernid/BayernIdPostfachServiceITCase.java @@ -0,0 +1,96 @@ +package de.itvsh.ozg.mail.postfach.bayernid; + +import static org.assertj.core.api.Assertions.*; +import static org.springframework.ws.test.client.RequestMatchers.*; +import static org.springframework.ws.test.client.ResponseCreators.*; + +import java.io.IOException; +import java.util.Collections; + +import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Test; +import org.junit.runner.RunWith; +import org.springframework.beans.factory.annotation.Autowired; +import org.springframework.beans.factory.annotation.Value; +import org.springframework.boot.test.context.SpringBootTest; +import org.springframework.core.io.Resource; +import org.springframework.test.context.ActiveProfiles; +import org.springframework.test.context.junit4.SpringRunner; +import org.springframework.ws.test.client.MockWebServiceServer; + +import de.itvsh.kop.common.test.ITCase; +import de.itvsh.ozg.mail.postfach.PostfachAddressTestFactory; +import de.itvsh.ozg.mail.postfach.PostfachBadRequestException; +import de.itvsh.ozg.mail.postfach.PostfachNachrichtTestFactory; +import de.itvsh.ozg.mail.postfach.StringBasedIdentifier; +import de.itvsh.ozg.pluto.PlutoServerApplication; +import lombok.val; + +@RunWith(SpringRunner.class) +@SpringBootTest(classes = { PlutoServerApplication.class, BayernIdProperties.class }) +@ITCase +@ActiveProfiles({ "itcase", "itcase-bayernid-postfach" }) +class BayernIdPostfachServiceITCase { + + @Autowired + private BayernIdPostfachRemoteService bayernIdPostfachRemoteService; + + @Autowired + private BayernIdPostfachClient bayernIdPostfachClient; + + @Value("classpath:bayernid/bsp-nachricht") + private Resource bspNachrichtNativeResource; + + @Value("classpath:bayernid/bsp-quittung") + private Resource bspQuittungNativeResource; + + @Value("classpath:bayernid/bsp-quittung-error-in-schema") + private Resource bspQuittungErrorNativeResource; + + private MockWebServiceServer mockWebServiceServer; + + @BeforeEach + void createMockWebServiceServer() { + mockWebServiceServer = MockWebServiceServer.createServer(bayernIdPostfachClient.getWSTemplate()); + } + + @Test + void shouldSendMessageSuccessfully() throws IOException { + mockWebServiceServer.expect(payload(bspNachrichtNativeResource)).andRespond(withPayload(bspQuittungNativeResource)); + + val nachricht = PostfachNachrichtTestFactory.createBuilder() + .vorgangId("1") + .postfachAddress(PostfachAddressTestFactory.createBuilder() + .type(PostfachAddressTestFactory.TYPE) + .version(PostfachAddressTestFactory.VERSION) + .identifier(StringBasedIdentifier.builder().postfachId("1").build()) + .build()) + .messageId("1") + .attachments(Collections.emptyList()) + .build(); + + assertThatCode(() -> bayernIdPostfachRemoteService.sendMessage(nachricht)).doesNotThrowAnyException(); + + mockWebServiceServer.verify(); + } + + @Test + void shouldThrowPostfachBadRequestException() throws IOException { + mockWebServiceServer.expect(payload(bspNachrichtNativeResource)).andRespond(withPayload(bspQuittungErrorNativeResource)); + + val nachricht = PostfachNachrichtTestFactory.createBuilder() + .vorgangId("1") + .postfachAddress(PostfachAddressTestFactory.createBuilder() + .type(PostfachAddressTestFactory.TYPE) + .version(PostfachAddressTestFactory.VERSION) + .identifier(StringBasedIdentifier.builder().postfachId("1").build()) + .build()) + .messageId("1") + .attachments(Collections.emptyList()) + .build(); + + assertThatThrownBy(() -> bayernIdPostfachRemoteService.sendMessage(nachricht)).isInstanceOf(PostfachBadRequestException.class); + + mockWebServiceServer.verify(); + } +} diff --git a/pluto-server/src/test/java/de/itvsh/ozg/mail/postfach/osi/OsiPostfachServiceITCase.java b/pluto-server/src/test/java/de/itvsh/ozg/mail/postfach/osi/OsiPostfachServiceITCase.java index aa1866a4c..bc9966216 100644 --- a/pluto-server/src/test/java/de/itvsh/ozg/mail/postfach/osi/OsiPostfachServiceITCase.java +++ b/pluto-server/src/test/java/de/itvsh/ozg/mail/postfach/osi/OsiPostfachServiceITCase.java @@ -29,7 +29,9 @@ import static org.springframework.test.web.client.response.MockRestResponseCreat import java.util.Collections; -import org.junit.jupiter.api.*; +import org.junit.jupiter.api.BeforeEach; +import org.junit.jupiter.api.Nested; +import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.http.MediaType; diff --git a/pluto-server/src/test/resources/application-itcase-bayernid-postfach.yml b/pluto-server/src/test/resources/application-itcase-bayernid-postfach.yml new file mode 100644 index 000000000..c2694bddb --- /dev/null +++ b/pluto-server/src/test/resources/application-itcase-bayernid-postfach.yml @@ -0,0 +1,13 @@ +ozgcloud: + bayernid: + server: http://localhost + zertifikat: + keystore: classpath:bayernid.p12 + password: SyPaRAxe97 + absender: + postkorbId: 28721c6f-b78f-4d5c-a048-19fd2fc429d2 + name: test name + anschrift: Niemalsgasse 5, 99999 Irgendwo Stadt + dienst: Stadtverwaltung + mandant: Fürth + gemeindeSchluessel: 09563000 \ No newline at end of file diff --git a/pluto-server/src/test/resources/application-itcase-osi-postfach.yml b/pluto-server/src/test/resources/application-itcase-osi-postfach.yml new file mode 100644 index 000000000..32f273be9 --- /dev/null +++ b/pluto-server/src/test/resources/application-itcase-osi-postfach.yml @@ -0,0 +1,9 @@ +kop: + osi: + postfach: + proxyapi: + url: http://localhost/ApiProxy/V1/Message + key: 1234 + realm: test-realm + notification: + mail-from: test@local.host diff --git a/pluto-server/src/test/resources/application-itcase.yml b/pluto-server/src/test/resources/application-itcase.yml index 8af9c9e71..56b72852a 100644 --- a/pluto-server/src/test/resources/application-itcase.yml +++ b/pluto-server/src/test/resources/application-itcase.yml @@ -12,15 +12,5 @@ grpc: aktenzeichen: de.itvsh.ozg.pluto.vorgang.AktenzeichenProviderEA -kop: - osi: - postfach: - proxyapi: - url: http://localhost/ApiProxy/V1/Message - key: 1234 - realm: test-realm - notification: - mail-from: test@local.host - mongock: enabled: false \ No newline at end of file diff --git a/pluto-server/src/test/resources/bayernid.p12 b/pluto-server/src/test/resources/bayernid.p12 new file mode 100644 index 0000000000000000000000000000000000000000..fa82ce9007cc50831496073cdb03d8b6a92b5ee4 GIT binary patch literal 6349 zcmXqLk~qo4$ZXIg(Zt57)#lOmotKfFaY2(rF-wy~zCn{jwm}o?bQCGp4wfd?7K0|% z27@Nn8a8gIE*>sMrUgwbzYUsLz8h$=alwQcnGK{_M3!p?sR<gE^S*x5W)*a{xogRa zPoJ5X8BQ>;G_jmeShiixahKAKj)Ft)e?79=_3qXt3D&RLZ@=oaCCvRb`x(psV&U~w zFB8wGgx_|`cD(d+-5VWa>zbX$NxpL>R@_P8mWU6%FmqF7Xw9{jyQ@=@o~EBtNnBGq zp>L<qEl=sWbq(j<DOmC|M?Tq=m=%9TXtLs@#5=!S7;B`h9)?W5d8GJ~?D;mSw5GxZ zDbfAuE8agn?`3=M#z%|Q*YZCaCR}D{J7MtUfJUBYGh69I+m$XWkG;26o_d?JYw<4m zV+SvtKM=((|5WjYlKiFO=VISI-q>l1iiW-qwQc`zmA;|Q(d^8;xdr#46;8H2^GOx% zQdOvRR=RLu{turiGqxY*P>yU>w+@K-)ArFg>aECpt%Yu>iW|6_?o4sGvva+j^_u2h z-P+x6R+yPTnO2tneCm9Yq`Sp}t&5k&s_vTn>So%TQ`Oq(QJ?2<2`c1#n7eO7{>Ovg zimrXTayH0(HS?c9S9#3@Hs@)AOT=9Qd~P+F_ZiG=eLp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SpWOlLARD`%X^xkP?_#P7EK zkM<UNt@t12{O`oowK1uSr2N+2O^H_xS2#Ake{byeEnCm++Om6ot_Y*&x=pKs#cSW1 zSM5KXX8f)5;?c7CQ@9^8Pit|A*Di0buXo(CRb%qZJO5{HwLX}~7*KJP<B#c$`+-pr zC4Zt+Cx$xp<}BQ>D|1mom!j2gRZ*KSN3Za2>HM)&-}CXOxFz~$OO{<SY7DArTCrm7 zq2QHnyUYG<7U=l&P>NqeSx%}@KXqcEpi$Rt`}ybM*q!(6wVb1{&+d#J({-c7it8u0 zaH>2go++54a4nc4I*Enh*#omU$ql;u(}nKO>74Fxo2T#F+kA$O25$Kxr(V(Xr!H}s zrHLGK|9@lhdg~O^$!`_J(*M*QnJfBx_iD3V*$K}|%+e-n%v-f=Yh3y=iBE1k3)^Qs z(XTz~d0vf4zroUTwvTT6%89%I=e9^$b1cobQ*!z-^)&BH?ebk#Yi>Wz{vi?An&_7z zWMF5YXu!$Fs?EpDB*n_WBC_|=0)w=*Udx@*zi=q&e4pVM_P~!t#D|Ml<;OLVKJ|B3 Tvzv}ZT5L>J)@Nd7oWKA8<KO^t literal 0 HcmV?d00001 diff --git a/pluto-server/src/test/resources/bayernid/bsp-nachricht b/pluto-server/src/test/resources/bayernid/bsp-nachricht new file mode 100644 index 000000000..531b80b09 --- /dev/null +++ b/pluto-server/src/test/resources/bayernid/bsp-nachricht @@ -0,0 +1 @@ +<ns4:sendBspNachrichtNative xmlns:ns3="http://www.akdb.de/egov/bsp/nachrichten" xmlns:ns4="urn:akdb:bsp:postkorb:komm:webservice"><bspNachricht><?xml version="1.0" encoding="UTF-8" standalone="yes"?><ns2:BspNachricht xmlns:ns2="http://www.akdb.de/egov/bsp/nachrichten" xmlns:ns3="urn:akdb:bsp:postkorb:komm:webservice"><ns2:NachrichtenKopf><ns2:Identifikation.Nachricht><ns2:Erstellungszeitpunkt>2020-04-01T10:30:10.000Z</ns2:Erstellungszeitpunkt><ns2:NachrichtenId>1</ns2:NachrichtenId></ns2:Identifikation.Nachricht><ns2:Absender><ns2:Dienst>Stadtverwaltung</ns2:Dienst><ns2:Mandant>Fürth</ns2:Mandant><ns2:Gemeindeschluessel><ns2:Tabelle>36</ns2:Tabelle><ns2:Schluessel>09563000</ns2:Schluessel></ns2:Gemeindeschluessel></ns2:Absender><ns2:Empfaenger><ns2:PostkorbId>1</ns2:PostkorbId></ns2:Empfaenger></ns2:NachrichtenKopf><ns2:NachrichtenInhalt><ns2:Betreff>Test Subject</ns2:Betreff><ns2:StorkQaaLevel>LEVEL_1</ns2:StorkQaaLevel><ns2:ZuVorgang><ns2:VorgangsId>1</ns2:VorgangsId></ns2:ZuVorgang><ns2:FreiText><ns2:Encoding><ns2:Tabelle>9004</ns2:Tabelle><ns2:Schluessel>text/plain</ns2:Schluessel></ns2:Encoding><ns2:Text>BodyString</ns2:Text></ns2:FreiText></ns2:NachrichtenInhalt></ns2:BspNachricht></bspNachricht></ns4:sendBspNachrichtNative> \ No newline at end of file diff --git a/pluto-server/src/test/resources/bayernid/bsp-quittung b/pluto-server/src/test/resources/bayernid/bsp-quittung new file mode 100644 index 000000000..15782e2e4 --- /dev/null +++ b/pluto-server/src/test/resources/bayernid/bsp-quittung @@ -0,0 +1,9 @@ +<ns2:sendBspNachrichtNativeOutput xmlns:ns2="urn:akdb:bsp:postkorb:komm:webservice"><bspQuittung><?xml version="1.0" encoding="UTF-8" standalone="yes"?> +<BspQuittung version="1.5" fassung="2020-03-15" xmlns="http://www.akdb.de/egov/bsp/nachrichten"> + <AnnahmeErfolgreich>true</AnnahmeErfolgreich> + <ErgebnisStatus> + <Tabelle>9006</Tabelle> + <Schluessel>0</Schluessel> + </ErgebnisStatus> +</BspQuittung> +</bspQuittung></ns2:sendBspNachrichtNativeOutput> \ No newline at end of file diff --git a/pluto-server/src/test/resources/bayernid/bsp-quittung-error-in-schema b/pluto-server/src/test/resources/bayernid/bsp-quittung-error-in-schema new file mode 100644 index 000000000..a1cbbc080 --- /dev/null +++ b/pluto-server/src/test/resources/bayernid/bsp-quittung-error-in-schema @@ -0,0 +1,9 @@ +<ns2:sendBspNachrichtNativeOutput xmlns:ns2="urn:akdb:bsp:postkorb:komm:webservice"><bspQuittung><?xml version="1.0" encoding="UTF-8" standalone="yes"?> +<BspQuittung version="1.5" fassung="2020-03-15" xmlns="http://www.akdb.de/egov/bsp/nachrichten"> + <AnnahmeErfolgreich>false</AnnahmeErfolgreich> + <ErgebnisStatus> + <Tabelle>9006</Tabelle> + <Schluessel>20</Schluessel> + </ErgebnisStatus> +</BspQuittung> +</bspQuittung></ns2:sendBspNachrichtNativeOutput> \ No newline at end of file -- GitLab