-
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
sundry fixes and improvements #8
Conversation
…rn an array of promises resulting from saveResourceTextFromServer calls (instead of undefined) (fix issue #3)
* add test scripts to package.json * make getGroupRDF.js more testable by lazily instantiating the sinopia server client, to make mocking it easier * add a test for the basic success case of getResourceTextFromServer, using a mock instance of the sinopia server client to avoid the need for network interactions
…lready. add unit test specific config.
pull up some mockSinopiaClient setup code that can be shared from a prior test, and import fs functions
fab6432
to
0a8e0db
Compare
587cab6
to
4963232
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.
pls add copyright/license statement at top of each file ...
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.
LGTM, modulo missing copyright/license statement
@@ -0,0 +1,61 @@ | |||
# Copyright 2019 Stanford University see LICENSE file | |||
# CircleCI 2.0 configuration file |
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 line 2 is sorta obvious, but 🤷
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 was actually copypasta from the sinopia_acl circle config that i ripped off, but happy to remove if it irks you.
@ndushay said:
good catch, added to not sure if that was the only one you intended that comment to apply to, but just in case: i didn't add to |
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.
Approve pending consideration of comment.
if(!clientInstance) { | ||
clientInstance = new SinopiaServer.LDPApi() | ||
clientInstance.apiClient.basePath = config.get('trellis.basePath') | ||
console.debug(`Sinopia Server client lazily instantiated. base URL: ${clientInstance.apiClient.basePath}`) |
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.
Cruft?
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.
hmm... despite it being debug
, that was intentional, just so the user would see clearly what server they're hitting (since it's otherwise buried in a config file).
but happy to remove if that's overkill. i had a bit more logging of that sort that i removed because i ended up feeling like it was unnecessary noise.
copyright all good now. - N |
merging because of the two approvals, but happy to reconsider the log statement that @justinlittman pointed out (can remove in a follow on PR if need be). |
config
package dependency, along with default configurationconnects to #1
closes LD4P/sinopia_editor#797