GQL icon indicating copy to clipboard operation
GQL copied to clipboard

tests/clean up

Open calvinmetcalf opened this issue 12 years ago • 8 comments

we need to add tests, wrap it in a umd, and make it available at least via npm

calvinmetcalf avatar Dec 28 '13 14:12 calvinmetcalf

also pinging @neojski as this is his baby

calvinmetcalf avatar Dec 28 '13 16:12 calvinmetcalf

also needs to require collate -- and an example of how to add it to your project, because it's not documented anywhere. Currently I've forked pouchdb and added it to the list of source files to include in the build.

I'm not clear how it's meant to work now that it's separated out into its own repository. Will I still need to have a custom npm build of pouchdb in order to use this?

marfarma avatar Dec 31 '13 22:12 marfarma

You can actually include it via a script tag and it will work On Dec 31, 2013 5:56 PM, "MarFarMa" [email protected] wrote:

also needs to require collate -- and an example of how to add it to your project, because it's not documented anywhere. Currently I've forked pouchdb and added it to the list of source files to include in the build.

I'm not clear how it's meant to work now that it's separated out into its own repository. Will I still need to have a custom npm build of pouchdb in order to use this?

— Reply to this email directly or view it on GitHubhttps://github.com/pouchdb/GQL/issues/1#issuecomment-31414335 .

calvinmetcalf avatar Dec 31 '13 23:12 calvinmetcalf

OK - I've forked it. What can I use to model the testing setup after? Do any of the other separated out plugins have tests I can copy to use as a starting point? Since I'm using it in my project, I'm motivated to get this plugin released on npm or bower.

Unless @neojski has time to pick this up?

marfarma avatar Dec 31 '13 23:12 marfarma

collate seems the most complete. Any reason not to copy over the setup from there - i.e. lib/index.js, test/test.js, project.json with the test and build tasks, dist/pouchdb-gql.js, etc.?

marfarma avatar Dec 31 '13 23:12 marfarma

Yes look at the map reduce or spatial, the mocha/chai/Istanbul set up which they use is pretty good. I can five you some help on Thursday until then you can copy the scripts section of the geopouch or map reduce package.json and install the deps with 'npm install --save-dev istanbul mocha chai' On Dec 31, 2013 6:17 PM, "MarFarMa" [email protected] wrote:

OK - I've forked it. What can I use to model the testing setup after? Do any of the other separated out plugins have tests I can copy to use as a starting point? Since I'm using it in my project, I'm motivated to get this plugin released on npm or bower.

Unless @neojski https://github.com/neojski has time to pick this up?

— Reply to this email directly or view it on GitHubhttps://github.com/pouchdb/GQL/issues/1#issuecomment-31414783 .

calvinmetcalf avatar Dec 31 '13 23:12 calvinmetcalf

@MarFarMa I added some very basic test scaffolding

calvinmetcalf avatar Jan 02 '14 16:01 calvinmetcalf

Thanks. That helps.

marfarma avatar Jan 02 '14 17:01 marfarma