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

Fix data-service CI failures #2691

Merged
merged 1 commit into from
May 4, 2022
Merged

Conversation

abhidg
Copy link
Contributor

@abhidg abhidg commented May 4, 2022

Data service CI was failing due to the notes removal change. After this,
setting the 'notes' field of a case document doesn't actually result in
a updated case, as the notes field is deleted by controllers, and it is
not returned from the data service APIs.

To simulate an updated document, this adds a pathogen key to a case.

@abhidg abhidg requested review from jim-sheldon and iamleeg May 4, 2022 10:00
@@ -1099,7 +1118,9 @@ export const casesMatchingSearchQuery = (opts: {
}): any => {
// set data limit to 10K by default
const countLimit = opts.limit ? opts.limit : 10000;
console.log(`Search query: ${opts.searchQuery}`);
Copy link
Contributor

Choose a reason for hiding this comment

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

switch to logger.debug?

@@ -779,13 +786,15 @@ describe('POST', () => {
const newCaseInDb = await Case.findOne({
'revisionMetadata.revisionNumber': 0,
});
console.log(newCaseInDb);
Copy link
Contributor

Choose a reason for hiding this comment

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

can be removed

Copy link
Contributor

@iamleeg iamleeg left a comment

Choose a reason for hiding this comment

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

Looks good, just need to tidy up some console.log

Data service CI was failing due to the notes removal change. After this,
setting the 'notes' field of a case document doesn't actually result in
a updated case, as the notes field is deleted by controllers, and it is
not returned from the data service APIs.

To simulate an updated document, this adds a pathogen key to a case.
@abhidg abhidg force-pushed the fix-data-service-ci-notes-removal branch from 1f49d9b to b2631d8 Compare May 4, 2022 10:19
@abhidg abhidg merged commit d06706d into main May 4, 2022
@abhidg abhidg deleted the fix-data-service-ci-notes-removal branch May 4, 2022 10:19
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

Successfully merging this pull request may close these issues.

None yet

2 participants