Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: public endpoint to verify contracts #69

Merged
merged 4 commits into from
Oct 27, 2023

Conversation

vasyl-ivanchuk
Copy link
Collaborator

What ❔

Public endpoint to verify contracts

Checklist

  • PR title corresponds to the body of PR (we generate changelog entries from PRs).
  • Tests for the changes have been added / updated.
  • Documentation comments have been added / updated.

@vasyl-ivanchuk vasyl-ivanchuk changed the title Add public endpoint to verify contracts feat: public endpoint to verify contracts Oct 26, 2023
@github-actions
Copy link

github-actions bot commented Oct 26, 2023

API E2E Test Results

202 tests   202 ✔️  39s ⏱️
  12 suites      0 💤
    1 files        0

Results for commit fe4cedb.

♻️ This comment has been updated with latest results.

@@ -62,12 +62,12 @@
"@typescript-eslint/parser": "^5.0.0",
"eslint-config-prettier": "^8.3.0",
"eslint-plugin-prettier": "^4.0.0",
"jest": "28.1.3",
"jest": "29.2.1",
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Update jest to fix an issue with open handlers for supertest request post functions.

@Query(new ParseActionPipe()) action: string,
@Query("module", new ParseModulePipe()) module: ApiModule,
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change the order so module pipe works before action pipe. Otherwise even if the module is not found, error about action will be returned.

@github-actions
Copy link

github-actions bot commented Oct 26, 2023

Unit Test Results

       3 files     240 suites   3m 25s ⏱️
1 873 tests 1 872 ✔️ 1 💤 0
1 899 runs  1 898 ✔️ 1 💤 0

Results for commit fe4cedb.

♻️ This comment has been updated with latest results.

@github-actions
Copy link

github-actions bot commented Oct 26, 2023

Visit the preview URL for this PR (updated for commit fe4cedb):

(expires Fri, 03 Nov 2023 11:55:26 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

Sign: e508f9012944951194447cb8885950b451a24403

@@ -3,7 +3,7 @@ import { INestApplication, ValidationPipe } from "@nestjs/common";
export const configureApp = (app: INestApplication) => {
app.useGlobalPipes(
new ValidationPipe({
disableErrorMessages: true,
disableErrorMessages: false,
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To return the description of 400 Bad Request Errors

@@ -61,13 +61,13 @@
"@typescript-eslint/parser": "^5.0.0",
"eslint-config-prettier": "^8.3.0",
"eslint-plugin-prettier": "^4.0.0",
"jest": "28.1.3",
"jest": "29.2.1",
Copy link
Collaborator Author

@vasyl-ivanchuk vasyl-ivanchuk Oct 26, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same update as for API, just to use the same lib versions.

expect(blockService.start).toBeCalledTimes(2);
expect(batchService.start).toBeCalledTimes(2);
expect(counterService.start).toBeCalledTimes(2);
expect(balancesCleanerService.start).toBeCalledTimes(2);
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Honestly, not sure how it worked before but these checks started to fail afterjest update. 2 - is the correct number of calls here, since 1st call happens on app init, and then the 2nd - while processing the revert event.

@vasyl-ivanchuk vasyl-ivanchuk merged commit 097cf01 into main Oct 27, 2023
24 checks passed
@vasyl-ivanchuk vasyl-ivanchuk deleted the add-public-endpoint-to-verify-contracts branch October 27, 2023 12:28
@github-actions
Copy link

🎉 This PR is included in version 2.19.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

pcheremu pushed a commit that referenced this pull request Feb 15, 2024
# What ❔

Public endpoint to verify contracts

## Checklist

<!-- Check your PR fulfills the following items. -->
<!-- For draft PRs check the boxes as you complete them. -->

- [X] PR title corresponds to the body of PR (we generate changelog
entries from PRs).
- [X] Tests for the changes have been added / updated.
- [X] Documentation comments have been added / updated.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants