-
Notifications
You must be signed in to change notification settings - Fork 682
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
Copies & renames useSearch to useBaseSearch in kolibri-common package (On develop this time) #12566
Copies & renames useSearch to useBaseSearch in kolibri-common package (On develop this time) #12566
Conversation
Build Artifacts
|
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.
I think two changes should ensure that the tests still run - but good to verify that they are still passing once these two changes have been made.
|
||
/* | ||
* TBD #12517 | ||
const { fetchContentNodeProgress } = useContentNodeProgress(); |
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 has been commented out, but is still referenced below. Can just implement a dummy function for now in addition to commenting this out:
const fetchContentNodeProgress = () => {};
* TBD #12517 | ||
const { baseurl } = currentDeviceData(store); | ||
*/ | ||
|
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.
Probably best to define:
const baseurl = '';
to ensure that references to it below are defined?
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.
I misled you with my suggestion, undefined
for baseurl should give us fully working tests.
Also, this edit in develop should be propagated here: https://github.com/learningequality/kolibri/pull/12573/files#diff-97998deaa1014b5d4a58ef1c85a053b09150ff10e17ef4daf78316221eecd67dR9 (best to do a rebase to confirm things are working as they should).
const labels = ref(null); | ||
|
||
// TODO: Kolibri #12517 - Will be injected in subsequent work | ||
const baseurl = ''; |
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.
Ah, sorry, the baseurl falsy checking is actually strictly checking for undefined
so setting this to:
const baseurl = undefined;
should allow all the tests to pass as expected.
}); | ||
// TODO: #12517 -- Once the injection & imports are working we should expect these tests to pass | ||
// and should no longer be skipped | ||
describe.skip('search method', () => { |
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.
With the change below, this skip can be removed.
877d434
to
9323112
Compare
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.
All comments addressed, good to merge once tests pass.
]; | ||
|
||
// TBD #12517 - Will be injected in subsequent work. | ||
const fetchContentNodeProgress = Promise.resolve({}); |
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 probably needs to be a function, but we can leave that for #12517 as it seems that tests are not checking this!
Summary
Closes #12516
kolibri-common
, adds TODO notes for subsequent work where things have been stubbed out to please the tests & linteruseBaseSearch.spec.js
file, a single section of the test suite is skipped because implementing fixes that would pass the tests are in the scope of Update Learn so that searching and filtering UI references newkolibri-common
components, and delete Learn-specific components #12518I've tried to make these changes in a way where, when @AlexVelezLl rebases on it, it should be super clear where he should be keeping his work vs the conflicting changes. Please lemme know if you hit any issues there.
References
Closes #12517
Reviewer guidance
Testing checklist