Skip to content

Commit

Permalink
Fix frontend tests
Browse files Browse the repository at this point in the history
  • Loading branch information
MiraGeowerkstatt committed Jul 28, 2022
1 parent 585fc30 commit a4ee42c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/ClientApp/cypress/integration/home.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ describe("Home page tests", () => {
it("Show search result box if search for grundbuchnummer", function () {
const gbnummer = "h5r0wdwsz6ef39zb2d31a0zfou7i4tdguvddcklb";
cy.intercept(
`/standort?gemeinde=&gbnummer=${gbnummer}&bezeichnung=&erstellungsdatum=&mutationsdatum=`,
`/standort?gemeinde=null&gbnummer=${gbnummer}&bezeichnung=&erstellungsdatum=&mutationsdatum=`,
standorteGbnummer
);
cy.visit("/");
Expand All @@ -41,7 +41,7 @@ describe("Home page tests", () => {

it("Show search result box if search for bezeichnung", function () {
cy.intercept(
`/standort?gemeinde=&gbnummer=&bezeichnung=Rustic%20Wooden%20Keyboard&erstellungsdatum=&mutationsdatum=`,
`/standort?gemeinde=null&gbnummer=&bezeichnung=Rustic%20Wooden%20Keyboard&erstellungsdatum=&mutationsdatum=`,
standorteBezeichnung
);
cy.visit("/");
Expand Down
1 change: 1 addition & 0 deletions src/ClientApp/src/components/Search.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ export default function Search(props) {
query += `&bezeichnung=${encodeURIComponent(formData.bezeichnung)}`;
query += `&erstellungsdatum=${formData.erstellungsDatum ? new Date(formData.erstellungsDatum).toDateString() : ""}`;
query += `&mutationsdatum=${formData.mutationsDatum ? new Date(formData.mutationsDatum).toDateString() : ""}`;
console.log(query);
getStandorte(query);
};

Expand Down

0 comments on commit a4ee42c

Please sign in to comment.