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

Migration Risk checklists to new API #3021

Open
Tracked by #2889
kepae opened this issue Aug 14, 2024 · 0 comments
Open
Tracked by #2889

Migration Risk checklists to new API #3021

kepae opened this issue Aug 14, 2024 · 0 comments
Assignees

Comments

@kepae
Copy link
Collaborator

kepae commented Aug 14, 2024

per @cesarvarela :

  • Convert Atlas checklist schema.json file to a GraphqlObject class and save it to server/types/checklist.ts (gpt is excellent for this)
  • Add a checklists field definition to server/fields/cheklists.ts (look at existing types for examples: server/fields/incidents.ts)
  • Convert rules.json to graphql-shield permissions and add them to server/fields/checklists.ts
  • Add a test fixture for checklists server/tests/fixtures/checklists.ts and add it to server/tests/mutation-fields.spec.ts and server/tests/query-fields.spec.ts
  • Migrate custom risks resolver to the checklists field file server/fields/checklists.ts
  • Add a Custom test for this resolver server/tests/checklists.ts

To run tests, npm run test:api.

To start a node server with only the API npm run start:api (helpful for debugging)

Note that the Graphql fields checklist and checklists signature changes; instead of receiving a query argument, the argument's name is filter, and the properties differ, so the front end needs to be updated accordingly.

@kepae kepae changed the title Risk checklists Migration Risk checklists to new API Aug 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants