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

Can't mock /api/inventory/v1/hosts #1883

Open
jelly opened this issue May 30, 2023 · 0 comments
Open

Can't mock /api/inventory/v1/hosts #1883

jelly opened this issue May 30, 2023 · 0 comments

Comments

@jelly
Copy link

jelly commented May 30, 2023

I'm trying to develop against a mocked inventory host as I rather not manually register a machine in the staging environment.

So I changed customProxy's context to /api/inventory/v1/groups but this seems to generate an error in the web application. The mock server logs have:

[14:16:33] › [HTTP SERVER] get /hosts ℹ  info      Request received
[14:16:33] ›     [NEGOTIATOR] ℹ  info      Request contains an accept header: application/json, text/plain, */*
[14:16:33] ›     [VALIDATOR] ✔  success   The request passed the validation rules. Looking for the best response
[14:16:33] ›     [NEGOTIATOR] ✔  success   Found a compatible content for application/json, text/plain, */*
[14:16:34] ›     [NEGOTIATOR] ✔  success   Responding with the requested status code 200
[14:16:34] ›     [VALIDATOR] ✖  error     Violation: response.body.results.0.facts.0 must have required property 'facts'
[14:16:34] ›     [VALIDATOR] ✖  error     Violation: response.body.results.0.facts.1 must have required property 'facts'
[14:16:34] ›     [VALIDATOR] ✖  error     Violation: response.body.results.0.facts.2 must have required property 'facts'
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

1 participant