Open nolanlawson opened 8 years ago
@nolanlawson thanks for taking the time to check out Avance. You already have a good handle on CouchDB bits it doesn't do. I'm backfilling these as I get time.
I just added a HEAD / and will check out the _all_docs and _bulk_docs issues which seem to fail.
I've not implemented any of _changes or attachments yet - so it wasn't a surprise to see the tests all go red.
TBH I'm glad it didn't segfault!
Cool project! :smiley: Thought I would give you some pointers about how to run and pass the PouchDB test suite, since it's a pretty good way to determine whether or not you fully implement the CouchDB API. (For the record, Cloudant and PouchDB Server are passing, and Couchbase Sync Gateway passes most of it. Not sure about rsync or Drupal Relaxed Web Services.)
To run the test suite:
(
BAIL=0
tells the test suite not to bail at the first test, which is good for debugging.)First thing that's not passing: you need to enable HEAD requests against
/
. Otherwise the PouchDB tests will not even start, because they think the server is down. (You'll see:Waiting for host to start ..... Host failed to start
.Second thing that's not passing:
_all_docs
is not passing all tests; see test output for details. Seems related tokey
/keys
/include_docs
. Note thatkeys
has different behavior for the other options; you need to include the deleted docs in order for it to pass.Third thing that's not passing: attachments. See
test.attachments.js
tests for details. PouchDB doesn't do multipart, so you just need to support base64 withapplication/json
.Fourth thing:
_bulk_docs
withnew_edits=false
. This is basically required for replication to function correctly, but it's kind of tricky.Fifth thing:
_changes
- not implemented yet?There are some other failures, but the steps above should give you a good starting point. The tests are all located in
tests/integration
, and you can also follow our testing instructions inTESTING.md
to run them one at a time. Let me know or cc @daleharvey if you need any guidance!