-
Notifications
You must be signed in to change notification settings - Fork 0
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
ndc-test #10
ndc-test #10
Conversation
…e selection field is empty
src/sqlGeneration.ts
Outdated
if (Object.keys(fieldsToSelect).length === 0) { | ||
return `*` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is not correct. In this case we can just return VALUE {}
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My bad. I missed it when removing extra code. Fixed it.
src/execution.ts
Outdated
if (sqlGenCtx.selectFields == null || sqlGenCtx.selectFields == undefined || Object.keys(sqlGenCtx.selectFields).length === 0) { | ||
queryResponse = []; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You won't need to do this if you are run SELECT VALUE {}
when fields
is an empty array.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is returning 500 internal error saying incorrect syntax near '{
I think there should be a script to do this. Then we can call this script as part of the CI pipeline too. |
Fix errors while running
ndc-test
How to test:
/script/app.js
usingnode app.js
- This will create a database, a container and add data to the emulator.connector_config_emulator.json
file as configuration for emulator andconnector_config.json
file for cloud.cargo run --bin ndc-test -- test --endpoint http://localhost:8080
in ndc-spec repoor follow the Readme.md for pre-existing snapshot tests