-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
Abstracted out the access to fetch the implementation for AdminServiceTest - TRUNK-1761 #51
Conversation
This is actually by Zabil. |
@@ -0,0 +1 @@ | |||
a sammple http response |
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.
sample misspelled
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 had created this file earlier to test url.open connection to use the file:https:/// protocol instead of the https:// protocol so that I could mock the url openconnection call. This is not needed anymore will take this off in my next commit
Looks good. No real sctructural changes needed, just a few convention-following updates and its ready to go! |
I will address the code review comments and merge this. Thanks Zabil! |
* Initial commit * Change name to esm-module-config * Get config module minimally working per MF-52 * Switch to typescript * Add travis config * Tree-shake Ramda * Install husky * Format; switch husky to concurrent run * Reorganize files * Fix build * MF-87 Config library should support nested config properties (openmrs#3) https://issues.openmrs.org/browse/MF-87 * MF-74 Config library should import default config file using import-map (openmrs#2) * Import config.json from import map working. Jest failing. 404s print to console. * Fix tests * Do lookup per Joel's advice -- much better error handling * Get tests working; put config-file resolution into a function; weird eslint error? * Fixing build * Upgrading dependencies * Fixing license and Travis deployment (openmrs#4) * Fixing license and Travis deployment * Self review * React hooks for MF-74 Config file from import-map (openmrs#5) * Get started. typescript failing with very verbose react type problems * Review feedback * WIP * Get things kinda-sorta working using config as global variable. useState is causing infinite recursion. * Feedback * Feedback * Link to documentation in the readme * Setting webpack jsonpFunction (openmrs#9) * The rest of React hooks for MF-74 Config file from import-map (openmrs#6) * Get things probably working * Remove cruft * Remove cruft; fix undefined check * Update src/react-hook/react-hook.tsx Co-Authored-By: Joel Denning <[email protected]> * Revert test changes back to more comfortable syntax; fix type error * Use async/await, not then * 1.1.0 * MF-119: useConfig support for multiple modules (openmrs#10) * MF-110: useConfig now supports being called from multiple modules * Self review * MF-53 Config library should validate String value (openmrs#8) * Add validators * Add isBoolean and isString validators * Simplify validation system * Revert "Simplify validation system" This reverts commit 4a93ad45f4eff974e3315b04573a0293a49d8436. * Simplify validator functions * MF-102 useConfig goes into infinite loop when invalid config is provided (openmrs#7) * MF-102 useConfig goes into infinite loop when invalid config is provided https://issues.openmrs.org/browse/MF-102 * 1.1.1 * Bump handlebars from 4.2.0 to 4.5.3 (openmrs#11) Bumps [handlebars](https://github.com/wycats/handlebars.js) from 4.2.0 to 4.5.3. - [Release notes](https://github.com/wycats/handlebars.js/releases) - [Changelog](https://github.com/wycats/handlebars.js/blob/master/release-notes.md) - [Commits](handlebars-lang/handlebars.js@v4.2.0...v4.5.3) Signed-off-by: dependabot[bot] <[email protected]> * Log errors when modules define schemas incorrectly (openmrs#12) * Throw errors when modules define schemas incorrectly * Just log error instead of throwing * Copy * Minimal array support (openmrs#13) * Arrays should support element-wise validation (openmrs#14) * Validating structure of array object elements (openmrs#15) * Array object validation (openmrs#16) * 1.2.0 * Clean and refactor; some minor changes to error messages (openmrs#17) * Security updates (openmrs#20) * Add function to output to Dev Tools (openmrs#19) * Fixed bug where multiple configs introduces undefined in the merged configs for a certain module (openmrs#18) * Fixed bug where imported configs via systemjs contains undefined entries * Added test-case to reproduce the bug that occurs * Narrowed down on the issue * Should be able to interpolate array element objects with defaults (openmrs#21) * Should be able to interpolate array element objects with defaults MF-98 Config library should support arrays of config objects * Tidy * 1.3.0 * Revert "Should be able to interpolate array element objects with defaults (openmrs#21)" (openmrs#24) This reverts commit 9746789. Co-authored-by: Fatma Ali <[email protected]> * 1.3.1 * Bump acorn from 5.7.3 to 5.7.4 (openmrs#26) Bumps [acorn](https://github.com/acornjs/acorn) from 5.7.3 to 5.7.4. - [Release notes](https://github.com/acornjs/acorn/releases) - [Commits](acornjs/acorn@5.7.3...5.7.4) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Attempt openmrs#2 at "Should be able to interpolate array element objects with defaults (openmrs#21)" (openmrs#25) Original was 9746789. Validators were mishandled. Added validators to the test and fixed. * Simplify multiple provides test (openmrs#28) * Verify that entire array objects can be validated (openmrs#27) * Updates and prettier (openmrs#30) * Shouldn't crash app on invalid configs (openmrs#29) * Shouldn't crash app on invalid configs * Prettier * Should recognize 'description' key (openmrs#31) * BREAKING: imported config-file should take priority over provided configs (openmrs#32) * Update README.md (openmrs#33) * Update README.md * Update README.md * Add npm badge (openmrs#34) * MF-220 upgrade vulnerable dependencies (openmrs#35) * Skip validation (openmrs#36) * Added ability to skip validations * skips validations for arrays * fixed prettier issues * exposing of validation method * Added ability to support validation of dictionaries (openmrs#37) * Added ability to support validation of dictionaries * Fixed prettier issues * responding to reviews * Added missing types * Dictionary skip validations (openmrs#39) * Added ability to skip validations for dictionary * mis-spelt skipValidations * Bump websocket-extensions from 0.1.3 to 0.1.4 (openmrs#40) Bumps [websocket-extensions](https://github.com/faye/websocket-extensions-node) from 0.1.3 to 0.1.4. - [Release notes](https://github.com/faye/websocket-extensions-node/releases) - [Changelog](https://github.com/faye/websocket-extensions-node/blob/master/CHANGELOG.md) - [Commits](faye/websocket-extensions-node@0.1.3...0.1.4) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Remove skipValidation, which has no valid use case as of yet (openmrs#41) * Add isUuid validator (openmrs#42) * Add isUuid * Fix CIEL external ID validation * Add bad CIEL External ID example * Add support for processConfig (openmrs#43) * Add typedoc (openmrs#45) * Get started with typedoc * Get typedoc working beautifully * Add husky hook * Switch to an API embedded directly in the README * hook test * Fixup * Undo JS autoformatting * Undo JS autoformatting again * Fix bug where generated API docs keep growing (openmrs#46) * Add generated TOC to README (openmrs#47) * MF:249 Fixed error while importing config.js from frontend directory (openmrs#48) * Update README.md * Add support for freeform objects (openmrs#49) * 1.4.0 * 2.0.0 * MF-178: ConfigurableLink in module-config (openmrs#38) * MF-178 ConfigurableLink in module-config -- part 1, navigate() * Implement navigate * Implement ConfigurableLink -- tests not working * Fix out of date comment * Fixup * Finish ConfigurableLink implementation * Fix API doc links to always refer to master (openmrs#50) * Fix API doc links to always refer to master * Pin typedoc version for 'library' mode support * Add a test, add documentation, actually export navigation components (openmrs#51) * Expose interpolateString; add validators for URL templates (openmrs#52) * 2.1.0 * Fix navigate to handle SPA routes correctly (openmrs#53) * Fix navigate to handle SPA routes correctly * Fix navigate to handle SPA routes correctly * 2.1.1 * Introduce isNumber validator (openmrs#55) * 2.2.0 * Bump lodash from 4.17.15 to 4.17.19 (openmrs#56) Bumps [lodash](https://github.com/lodash/lodash) from 4.17.15 to 4.17.19. - [Release notes](https://github.com/lodash/lodash/releases) - [Commits](lodash/lodash@4.17.15...4.17.19) Signed-off-by: dependabot[bot] <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Add devDefault keyword, toggled on window.openmrsConfigUseDevDefaults (openmrs#57) * Dev toggle should use localStorage, not window (openmrs#58) * All validators should reject undefined (openmrs#59) * MF-309 Add support for a temporary config in localStorage (openmrs#60) * MF-309 Add support for a temporary config in localStorage * Add more schema validation * Schema validation should allow arrayElements to have keys without defaults (openmrs#61) * Adapt esm-config to lerna repo Co-authored-by: Joel Denning <[email protected]> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Nicky Kibor Kimaina <[email protected]> Co-authored-by: Jonathan Dick <[email protected]> Co-authored-by: Fatma Ali <[email protected]> Co-authored-by: Ramakrishnan Kandasamy <[email protected]> Co-authored-by: Donald Kibet <[email protected]> Co-authored-by: Mritunjay Dubey <[email protected]>
This change mocks out the internet access that was being done for fetching the implementation which resulted in the AdministrationServiceTest hanging.
Ticket: https://tickets.openmrs.org/browse/TRUNK-1761