You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by ja...@apache.org on 2020/01/04 17:13:27 UTC

[couchdb] branch multi/elixir-3 created (now d2f2751)

This is an automated email from the ASF dual-hosted git repository.

jan pushed a change to branch multi/elixir-3
in repository https://gitbox.apache.org/repos/asf/couchdb.git.


      at d2f2751  disable more JS tests

This branch includes the following new commits:

     new 9ea9fa0  Port UTF8 js test suite to elixir
     new b76a8b6  fix: losen assertion
     new 7a2df49  Merge remote-tracking branch 'dottorblaster/update-elixir-test-suite-README' into port-utf8-tests-js-elixir
     new 5415c3a  Merge remote-tracking branch 'origin/feat/js-to-exs' into multi/elixir
     new b5af4c4  Merge remote-tracking branch 'jjrodrig/port-elixir-auth' into multi/elixir-3
     new d2f2751  disable more JS tests

The 6 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.



[couchdb] 04/06: Merge remote-tracking branch 'origin/feat/js-to-exs' into multi/elixir

Posted by ja...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

jan pushed a commit to branch multi/elixir-3
in repository https://gitbox.apache.org/repos/asf/couchdb.git

commit 5415c3a696495730d5de45ddf339711a205a81b7
Merge: 7a2df49 20e7b2e
Author: Jan Lehnardt <ja...@apache.org>
AuthorDate: Sat Jan 4 18:08:46 2020 +0100

    Merge remote-tracking branch 'origin/feat/js-to-exs' into multi/elixir
    
    * origin/feat/js-to-exs:
      Disable all JS tests that have Elixir test counterparts.

 Makefile                                           | 37 ++--------------------
 test/elixir/test/replication_test.exs              |  2 +-
 .../tests-cluster/with-quorum/attachments.js       |  1 +
 .../with-quorum/attachments_delete.js              |  1 +
 .../attachments_delete_overridden_quorum.js        |  1 +
 .../with-quorum/attachments_overridden_quorum.js   |  1 +
 .../tests-cluster/with-quorum/db_creation.js       |  1 +
 .../with-quorum/db_creation_overridden_quorum.js   |  1 +
 .../tests-cluster/with-quorum/db_deletion.js       |  1 +
 .../with-quorum/db_deletion_overridden_quorum.js   |  1 +
 .../tests-cluster/with-quorum/doc_bulk.js          |  1 +
 .../with-quorum/doc_bulk_overridden_quorum.js      |  1 +
 .../tests-cluster/with-quorum/doc_copy.js          |  1 +
 .../with-quorum/doc_copy_overridden_quorum.js      |  1 +
 .../tests-cluster/with-quorum/doc_crud.js          |  1 +
 .../with-quorum/doc_crud_overridden_quorum.js      |  1 +
 .../tests-cluster/without-quorum/attachments.js    |  1 +
 .../without-quorum/attachments_delete.js           |  1 +
 .../attachments_delete_overridden_quorum.js        |  1 +
 .../attachments_overridden_quorum.js               |  1 +
 .../tests-cluster/without-quorum/db_creation.js    |  1 +
 .../db_creation_overridden_quorum.js               |  1 +
 .../tests-cluster/without-quorum/db_deletion.js    |  1 +
 .../db_deletion_overridden_quorum.js               |  1 +
 .../tests-cluster/without-quorum/doc_bulk.js       |  1 +
 .../without-quorum/doc_bulk_overridden_quorum.js   |  1 +
 .../tests-cluster/without-quorum/doc_copy.js       |  1 +
 .../without-quorum/doc_copy_overridden_quorum.js   |  1 +
 .../tests-cluster/without-quorum/doc_crud.js       |  1 +
 .../without-quorum/doc_crud_overridden_quorum.js   |  1 +
 test/javascript/tests/all_docs.js                  |  1 +
 test/javascript/tests/attachment_names.js          |  1 +
 test/javascript/tests/attachment_paths.js          |  1 +
 test/javascript/tests/attachment_ranges.js         |  1 +
 test/javascript/tests/attachment_views.js          |  1 +
 test/javascript/tests/attachments.js               |  1 +
 test/javascript/tests/attachments_multipart.js     |  1 +
 test/javascript/tests/basics.js                    |  2 +-
 test/javascript/tests/batch_save.js                |  1 +
 test/javascript/tests/bulk_docs.js                 |  1 +
 test/javascript/tests/coffee.js                    |  1 +
 test/javascript/tests/compact.js                   |  1 +
 test/javascript/tests/config.js                    |  1 +
 test/javascript/tests/conflicts.js                 |  1 +
 test/javascript/tests/copy_doc.js                  |  1 +
 test/javascript/tests/invalid_docids.js            |  1 +
 test/javascript/tests/large_docs.js                |  1 +
 test/javascript/tests/lots_of_docs.js              |  1 +
 test/javascript/tests/multiple_rows.js             |  1 +
 test/javascript/tests/reduce.js                    |  1 +
 test/javascript/tests/utf8.js                      |  1 +
 test/javascript/tests/uuids.js                     |  1 +
 test/javascript/tests/view_collation.js            |  1 +
 53 files changed, 54 insertions(+), 37 deletions(-)

diff --cc Makefile
index 0d4131a,f045a0e..66b1714
--- a/Makefile
+++ b/Makefile
@@@ -286,42 -280,39 +286,9 @@@ endi
              'test/javascript/run --suites "$(suites)" \
              --ignore "$(ignore_js_suites)"'
  
- .PHONY: test-cluster-with-quorum
- test-cluster-with-quorum: export COUCHDB_TEST_ADMIN_PARTY_OVERRIDE=1
- test-cluster-with-quorum: devclean
- 	@mkdir -p share/www/script/test
- ifeq ($(IN_RELEASE), true)
- 	@cp test/javascript/tests/lorem*.txt share/www/script/test/
- else
- 	@mkdir -p src/fauxton/dist/release/test
- 	@cp test/javascript/tests/lorem*.txt src/fauxton/dist/release/test/
- endif
- 	@dev/run -n 3 -q --with-admin-party-please \
-             --enable-erlang-views --degrade-cluster 1 \
-             "$(TEST_OPTS)" \
-             'test/javascript/run --suites "$(suites)" \
-             --ignore "$(ignore_js_suites)" \
- 	    --path test/javascript/tests-cluster/with-quorum'
- 
- .PHONY: test-cluster-without-quorum
- test-cluster-without-quorum: export COUCHDB_TEST_ADMIN_PARTY_OVERRIDE=1
- test-cluster-without-quorum: devclean
- 	@mkdir -p share/www/script/test
- ifeq ($(IN_RELEASE), true)
- 	@cp test/javascript/tests/lorem*.txt share/www/script/test/
- else
- 	@mkdir -p src/fauxton/dist/release/test
- 	@cp test/javascript/tests/lorem*.txt src/fauxton/dist/release/test/
- endif
- 	@dev/run -n 3 -q --with-admin-party-please \
-             --enable-erlang-views --degrade-cluster 2 \
-             "$(TEST_OPTS)" \
-             'test/javascript/run --suites "$(suites)" \
-             --ignore "$(ignore_js_suites)" \
-             --path test/javascript/tests-cluster/without-quorum'
 -# .PHONY: test-cluster-with-quorum
 -# test-cluster-with-quorum: devclean
 -# 	@mkdir -p share/www/script/test
 -# ifeq ($(IN_RELEASE), true)
 -# 	@cp test/javascript/tests/lorem*.txt share/www/script/test/
 -# else
 -# 	@mkdir -p src/fauxton/dist/release/test
 -# 	@cp test/javascript/tests/lorem*.txt src/fauxton/dist/release/test/
 -# endif
 -# 	@dev/run -n 3 -q --with-admin-party-please \
 -#             --enable-erlang-views --degrade-cluster 1 \
 -#             -c 'startup_jitter=0' \
 -#             'test/javascript/run --suites "$(suites)" \
 -#             --ignore "$(ignore_js_suites)" \
 -# 	    --path test/javascript/tests-cluster/with-quorum'
 -#
 -# .PHONY: test-cluster-without-quorum
 -# test-cluster-without-quorum: devclean
 -# 	@mkdir -p share/www/script/test
 -# ifeq ($(IN_RELEASE), true)
 -# 	@cp test/javascript/tests/lorem*.txt share/www/script/test/
 -# else
 -# 	@mkdir -p src/fauxton/dist/release/test
 -# 	@cp test/javascript/tests/lorem*.txt src/fauxton/dist/release/test/
 -# endif
 -# 	@dev/run -n 3 -q --with-admin-party-please \
 -#             --enable-erlang-views --degrade-cluster 2 \
 -#             -c 'startup_jitter=0' \
 -#             'test/javascript/run --suites "$(suites)" \
 -#             --ignore "$(ignore_js_suites)" \
 -#             --path test/javascript/tests-cluster/without-quorum'
  
  .PHONY: soak-javascript
 +soak-javascript: export COUCHDB_TEST_ADMIN_PARTY_OVERRIDE=1
  soak-javascript:
  	@mkdir -p share/www/script/test
  ifeq ($(IN_RELEASE), true)
diff --cc test/javascript/tests-cluster/with-quorum/attachments_delete_overridden_quorum.js
index 79c070e,fe969ea..48c1f34
--- a/test/javascript/tests-cluster/with-quorum/attachments_delete_overridden_quorum.js
+++ b/test/javascript/tests-cluster/with-quorum/attachments_delete_overridden_quorum.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.skip = true;
  couchTests.attachments_delete_overridden_quorum= function(debug) {
+   return console.log('done in test/elixir/test/cluster_with_quorum_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"},{"w":3});
    db.createDb();
diff --cc test/javascript/tests-cluster/with-quorum/attachments_overridden_quorum.js
index f9deb15,881c991..cbeb985
--- a/test/javascript/tests-cluster/with-quorum/attachments_overridden_quorum.js
+++ b/test/javascript/tests-cluster/with-quorum/attachments_overridden_quorum.js
@@@ -11,8 -11,8 +11,9 @@@
  // the License.
  
  //Test attachments operations with an overridden quorum parameter
 +couchTests.skip = true;
  couchTests.attachments_overriden_quorum= function(debug) {
+   return console.log('done in test/elixir/test/cluster_with_quorum_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"},{"w":3});
    db.createDb();
diff --cc test/javascript/tests-cluster/with-quorum/db_creation_overridden_quorum.js
index 1e69cd8,68164e6..af27f95
--- a/test/javascript/tests-cluster/with-quorum/db_creation_overridden_quorum.js
+++ b/test/javascript/tests-cluster/with-quorum/db_creation_overridden_quorum.js
@@@ -11,8 -11,8 +11,9 @@@
  // the License.
  
  // Do DB creation under cluster with quorum conditions but overriding write quorum.
 +couchTests.skip = true;
  couchTests.db_creation_overridden_quorum = function(debug) {
+   return console.log('done in test/elixir/test/cluster_with_quorum_test.exs');
  
    if (debug) debugger;
  
diff --cc test/javascript/tests-cluster/with-quorum/doc_copy_overridden_quorum.js
index 1ceef97,b87ff91..a816817
--- a/test/javascript/tests-cluster/with-quorum/doc_copy_overridden_quorum.js
+++ b/test/javascript/tests-cluster/with-quorum/doc_copy_overridden_quorum.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.skip = true;
  couchTests.doc_copy_overriden_quorum = function(debug) {
+   return console.log('done in test/elixir/test/cluster_with_quorum_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"},{"w":3});
    db.createDb();
diff --cc test/javascript/tests-cluster/without-quorum/attachments_delete.js
index 48a33d2,47ca0a0..8b8a2db
--- a/test/javascript/tests-cluster/without-quorum/attachments_delete.js
+++ b/test/javascript/tests-cluster/without-quorum/attachments_delete.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.skip = true;
  couchTests.attachments_delete= function(debug) {
+   return console.log('done in test/elixir/test/cluster_without_quorum_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();
diff --cc test/javascript/tests-cluster/without-quorum/attachments_delete_overridden_quorum.js
index c3b95f8,3dcbc10..48247e0
--- a/test/javascript/tests-cluster/without-quorum/attachments_delete_overridden_quorum.js
+++ b/test/javascript/tests-cluster/without-quorum/attachments_delete_overridden_quorum.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.skip = true;
  couchTests.attachments_delete_overridden_quorum= function(debug) {
+   return console.log('done in test/elixir/test/cluster_without_quorum_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"},{"w":1});
    db.createDb();
diff --cc test/javascript/tests-cluster/without-quorum/db_creation_overridden_quorum.js
index 7cee52e,bb77e15..8ed9b44
--- a/test/javascript/tests-cluster/without-quorum/db_creation_overridden_quorum.js
+++ b/test/javascript/tests-cluster/without-quorum/db_creation_overridden_quorum.js
@@@ -11,8 -11,8 +11,9 @@@
  // the License.
  
  // Do DB creation under cluster with quorum conditions but overriding write quorum.
 +couchTests.skip = true;
  couchTests.db_creation_overridden_quorum = function(debug) {
+   return console.log('done in test/elixir/test/cluster_without_quorum_test.exs');
  
    if (debug) debugger;
  
diff --cc test/javascript/tests-cluster/without-quorum/doc_copy_overridden_quorum.js
index bf372ca,d4db1c2..301240e
--- a/test/javascript/tests-cluster/without-quorum/doc_copy_overridden_quorum.js
+++ b/test/javascript/tests-cluster/without-quorum/doc_copy_overridden_quorum.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.skip = true;
  couchTests.doc_copy_overriden_quorum = function(debug) {
+   return console.log('done in test/elixir/test/cluster_without_quorum_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"},{"w":1});
    db.createDb();
diff --cc test/javascript/tests/all_docs.js
index a360fb9,3aa0047..0eb382f
--- a/test/javascript/tests/all_docs.js
+++ b/test/javascript/tests/all_docs.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.all_docs = function(debug) {
+   return console.log('done in test/elixir/test/all_docs_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"}, {w: 3});
    db.createDb();
diff --cc test/javascript/tests/attachment_names.js
index 4e9217c,a8011cb..16a23ac
--- a/test/javascript/tests/attachment_names.js
+++ b/test/javascript/tests/attachment_names.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.attachment_names = function(debug) {
+   return console.log('done in test/elixir/test/attachment_names_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"}, {w: 3});
    db.createDb();
diff --cc test/javascript/tests/attachment_paths.js
index 048640d,6f94750..b8c6a79
--- a/test/javascript/tests/attachment_paths.js
+++ b/test/javascript/tests/attachment_paths.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.attachment_paths = function(debug) {
+   return console.log('done in test/elixir/test/attachment_paths_test.exs');
    if (debug) debugger;
    var r_db_name = get_random_db_name()
    var dbNames = [r_db_name, r_db_name + "/with_slashes"];
diff --cc test/javascript/tests/attachment_ranges.js
index 37700ec,3c2b62e..564885c
--- a/test/javascript/tests/attachment_ranges.js
+++ b/test/javascript/tests/attachment_ranges.js
@@@ -14,8 -14,8 +14,9 @@@ function cacheBust() 
      return "?anti-cache=" + String(Math.round(Math.random() * 1000000));
  };
  
 +couchTests.elixir = true;
  couchTests.attachment_ranges = function(debug) {
+     return console.log('done in test/elixir/test/attachment_ranges_test.exs');
      var db_name = get_random_db_name();
      var db = new CouchDB(db_name, {
          "X-Couch-Full-Commit": "false"
diff --cc test/javascript/tests/attachment_views.js
index 7be32a9,9eefe23..c6c4b18
--- a/test/javascript/tests/attachment_views.js
+++ b/test/javascript/tests/attachment_views.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.attachment_views= function(debug) {
+   return console.log('done in test/elixir/test/attachment_views_test.exs');
  
    var db_name = get_random_db_name()
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
diff --cc test/javascript/tests/attachments.js
index 09c6acd,c366772..61fe8b9
--- a/test/javascript/tests/attachments.js
+++ b/test/javascript/tests/attachments.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.attachments= function(debug) {
+   return console.log('done in test/elixir/test/attachment_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();
diff --cc test/javascript/tests/attachments_multipart.js
index c36083f,e03783b..793c8c9
--- a/test/javascript/tests/attachments_multipart.js
+++ b/test/javascript/tests/attachments_multipart.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.attachments_multipart= function(debug) {
+   return console.log('done in test/elixir/test/attachment_multipart_test.exs');
    var db_name = get_random_db_name()
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();
diff --cc test/javascript/tests/basics.js
index edf9692,25ba984..51abb40
--- a/test/javascript/tests/basics.js
+++ b/test/javascript/tests/basics.js
@@@ -11,9 -11,8 +11,9 @@@
  // the License.
  
  // Do some basic tests.
 +couchTests.elixir = true;
  couchTests.basics = function(debug) {
- 
+   return console.log('done in test/elixir/test/basics_test.exs');
    if (debug) debugger;
  
    var result = JSON.parse(CouchDB.request("GET", "/").responseText);
diff --cc test/javascript/tests/batch_save.js
index 1f85b12,1e5a8db..bbfb2ed
--- a/test/javascript/tests/batch_save.js
+++ b/test/javascript/tests/batch_save.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.batch_save = function(debug) {
+   return console.log('done in test/elixir/test/batch_save_test.exs');
    var db_name = get_random_db_name()
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();
diff --cc test/javascript/tests/bulk_docs.js
index 7e65ae3,17aeb15..767a543
--- a/test/javascript/tests/bulk_docs.js
+++ b/test/javascript/tests/bulk_docs.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.bulk_docs = function(debug) {
+   return console.log('done in test/elixir/test/basics_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();
diff --cc test/javascript/tests/coffee.js
index 747bacf,44c9206..42a1a68
--- a/test/javascript/tests/coffee.js
+++ b/test/javascript/tests/coffee.js
@@@ -11,8 -11,8 +11,9 @@@
  // the License.
  
  // test basic coffeescript functionality
 +couchTests.elixir = true;
  couchTests.coffee = function(debug) {
+   return console.log('done in test/elixir/test/coffee_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();
diff --cc test/javascript/tests/compact.js
index 2b9dd21,90f75bb..fa05e30
--- a/test/javascript/tests/compact.js
+++ b/test/javascript/tests/compact.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.compact = function(debug) {
+   return console.log('done in test/elixir/test/coffee_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();
diff --cc test/javascript/tests/config.js
index 889cbd0,f88facb..e3cacc2
--- a/test/javascript/tests/config.js
+++ b/test/javascript/tests/config.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.config = function(debug) {
+   return console.log('done in test/elixir/test/config_test.exs');
    if (debug) debugger;
  
    // test that /_config returns all the settings
diff --cc test/javascript/tests/conflicts.js
index 7b5e020,69bfde6..ab25e62
--- a/test/javascript/tests/conflicts.js
+++ b/test/javascript/tests/conflicts.js
@@@ -11,8 -11,8 +11,9 @@@
  // the License.
  
  // Do some edit conflict detection tests
 +couchTests.elixir = true;
  couchTests.conflicts = function(debug) {
+   return console.log('done in test/elixir/test/conflicts_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();
diff --cc test/javascript/tests/copy_doc.js
index 708fe53,88ecfb1..107732c
--- a/test/javascript/tests/copy_doc.js
+++ b/test/javascript/tests/copy_doc.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.copy_doc = function(debug) {
+   return console.log('done in test/elixir/test/copy_doc_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();
diff --cc test/javascript/tests/invalid_docids.js
index 74f0e4f,1e22616..31c9d6c
--- a/test/javascript/tests/invalid_docids.js
+++ b/test/javascript/tests/invalid_docids.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.invalid_docids = function(debug) {
+   return console.log('done in test/elixir/test/invalid_docids_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();
diff --cc test/javascript/tests/large_docs.js
index bc9d22c,ad291e1..aa36b6c
--- a/test/javascript/tests/large_docs.js
+++ b/test/javascript/tests/large_docs.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.large_docs = function(debug) {
+   return console.log('done in test/elixir/test/large_docs_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();
diff --cc test/javascript/tests/lots_of_docs.js
index dc1486a,b47c3fb..453c652
--- a/test/javascript/tests/lots_of_docs.js
+++ b/test/javascript/tests/lots_of_docs.js
@@@ -11,8 -11,8 +11,9 @@@
  // the License.
  
  // test saving a semi-large quanitity of documents and do some view queries.
 +couchTests.elixir = true;
  couchTests.lots_of_docs = function(debug) {
+   return console.log('done in test/elixir/test/lots_of_docs_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();
diff --cc test/javascript/tests/multiple_rows.js
index 5bac8ab,b985683..b061044
--- a/test/javascript/tests/multiple_rows.js
+++ b/test/javascript/tests/multiple_rows.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.multiple_rows = function(debug) {
+   return console.log('done in test/elixir/test/multiple_rows_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();
diff --cc test/javascript/tests/reduce.js
index 6b8ea18,ede0aa7..c25ca77
--- a/test/javascript/tests/reduce.js
+++ b/test/javascript/tests/reduce.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.reduce = function(debug) {
+   return console.log('done in test/elixir/test/reduce_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();
diff --cc test/javascript/tests/utf8.js
index a724580,a724580..a1092c1
--- a/test/javascript/tests/utf8.js
+++ b/test/javascript/tests/utf8.js
@@@ -11,6 -11,6 +11,7 @@@
  // the License.
  
  couchTests.utf8 = function(debug) {
++  return console.log('done in test/elixir/test/utf8_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();
diff --cc test/javascript/tests/uuids.js
index cbf5e8e,dfd2971..18871ec
--- a/test/javascript/tests/uuids.js
+++ b/test/javascript/tests/uuids.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.uuids = function(debug) {
+   return console.log('done in test/elixir/test/uuids_test.exs');
    var etags = [];
    var testHashBustingHeaders = function(xhr) {
      T(xhr.getResponseHeader("Cache-Control").match(/no-cache/));
diff --cc test/javascript/tests/view_collation.js
index 7391fc8,523969b..3ec9f8a
--- a/test/javascript/tests/view_collation.js
+++ b/test/javascript/tests/view_collation.js
@@@ -10,8 -10,8 +10,9 @@@
  // License for the specific language governing permissions and limitations under
  // the License.
  
 +couchTests.elixir = true;
  couchTests.view_collation = function(debug) {
+   return console.log('done in test/elixir/test/view_collation_test.exs');
    var db_name = get_random_db_name();
    var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
    db.createDb();


[couchdb] 06/06: disable more JS tests

Posted by ja...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

jan pushed a commit to branch multi/elixir-3
in repository https://gitbox.apache.org/repos/asf/couchdb.git

commit d2f27510e5c3fe46d517975b26c3c82a3d892e53
Author: Jan Lehnardt <ja...@apache.org>
AuthorDate: Sat Jan 4 18:13:02 2020 +0100

    disable more JS tests
---
 test/elixir/README.md                | 2 +-
 test/javascript/tests/auth_cache.js  | 1 +
 test/javascript/tests/cookie_auth.js | 1 +
 test/javascript/tests/users_db.js    | 1 +
 4 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/test/elixir/README.md b/test/elixir/README.md
index 7984bdc..ef95e5f 100644
--- a/test/elixir/README.md
+++ b/test/elixir/README.md
@@ -31,7 +31,7 @@ X means done, - means partially
   - [X] Port attachments.js
   - [X] Port attachments_multipart.js
   - [X] Port attachment_views.js
-  - [ ] Port auth_cache.js
+  - [X] Port auth_cache.js
   - [X] Port basics.js
   - [X] Port batch_save.js
   - [X] Port bulk_docs.js
diff --git a/test/javascript/tests/auth_cache.js b/test/javascript/tests/auth_cache.js
index 4d35d82..ca8f077 100644
--- a/test/javascript/tests/auth_cache.js
+++ b/test/javascript/tests/auth_cache.js
@@ -11,6 +11,7 @@
 // the License.
 
 couchTests.auth_cache = function(debug) {
+  return console.log('done in test/elixir/test/auth_cache_test.exs');
   if (debug) debugger;
 
   // Simple secret key generator
diff --git a/test/javascript/tests/cookie_auth.js b/test/javascript/tests/cookie_auth.js
index 5c8ce89..0dce6bd 100644
--- a/test/javascript/tests/cookie_auth.js
+++ b/test/javascript/tests/cookie_auth.js
@@ -12,6 +12,7 @@
 
 couchTests.cookie_auth = function(debug) {
   // This tests cookie-based authentication.
+  return console.log('done in test/elixir/test/cookie_auth_test.exs');
 
   var db_name = get_random_db_name();
   var db = new CouchDB(db_name, {"X-Couch-Full-Commit":"false"});
diff --git a/test/javascript/tests/users_db.js b/test/javascript/tests/users_db.js
index 20be325..b13adff 100644
--- a/test/javascript/tests/users_db.js
+++ b/test/javascript/tests/users_db.js
@@ -11,6 +11,7 @@
 // the License.
 
 couchTests.users_db = function(debug) {
+  return console.log('done in test/elixir/test/users_db_test.exs');
 
   // This tests the users db, especially validations
   // this should also test that you can log into the couch


[couchdb] 05/06: Merge remote-tracking branch 'jjrodrig/port-elixir-auth' into multi/elixir-3

Posted by ja...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

jan pushed a commit to branch multi/elixir-3
in repository https://gitbox.apache.org/repos/asf/couchdb.git

commit b5af4c48bbfc515303907171f2148c1fe4989be1
Merge: 5415c3a d484b86
Author: Jan Lehnardt <ja...@apache.org>
AuthorDate: Sat Jan 4 18:10:03 2020 +0100

    Merge remote-tracking branch 'jjrodrig/port-elixir-auth' into multi/elixir-3
    
    * jjrodrig/port-elixir-auth:
      auth cache test is disabled
      Disable auth_cache_test
      Convert test setup/teardown logic into idiomatic ExUnit and use @moduletag config
      Correct test name
      Correct test name
      Cookie auth test fixes
      Cookie auth test fixes
      Auth cache test fixes
      WIP: increase default timeout, revert to fail when login error
      WIP: make test more robust
      Port users_db from js test suite to elixir
      remove debug log level config
      Remove conflicting functions
      Port cookie_auth test suite into elixir
      Add auth cache test into elixir test suite

 test/elixir/README.md                 |   4 +-
 test/elixir/lib/couch.ex              |  33 ++-
 test/elixir/lib/couch/db_test.ex      |  66 ++++--
 test/elixir/test/auth_cache_test.exs  | 212 ++++++++++++++++++
 test/elixir/test/cookie_auth_test.exs | 403 ++++++++++++++++++++++++++++++++++
 test/elixir/test/users_db_test.exs    | 322 +++++++++++++++++++++++++++
 6 files changed, 1015 insertions(+), 25 deletions(-)

diff --cc test/elixir/README.md
index 9e86172,87deb0e..7984bdc
--- a/test/elixir/README.md
+++ b/test/elixir/README.md
@@@ -93,9 -93,9 +93,9 @@@ X means done, - means partiall
    - [ ] Port show_documents.js
    - [ ] Port stats.js
    - [ ] Port update_documents.js
-   - [ ] Port users_db.js
+   - [X] Port users_db.js
    - [ ] Port users_db_security.js
 -  - [ ] Port utf8.js
 +  - [X] Port utf8.js
    - [X] Port uuids.js
    - [X] Port view_collation.js
    - [ ] Port view_collation_raw.js


[couchdb] 02/06: fix: losen assertion

Posted by ja...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

jan pushed a commit to branch multi/elixir-3
in repository https://gitbox.apache.org/repos/asf/couchdb.git

commit b76a8b6c76d91b43db729d31dd50d24ced819e34
Author: Jan Lehnardt <ja...@apache.org>
AuthorDate: Sat Jan 4 17:54:08 2020 +0100

    fix: losen assertion
---
 test/elixir/test/utf8_test.exs | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/test/elixir/test/utf8_test.exs b/test/elixir/test/utf8_test.exs
index 4153710..ad78080 100644
--- a/test/elixir/test/utf8_test.exs
+++ b/test/elixir/test/utf8_test.exs
@@ -24,7 +24,7 @@ defmodule UTF8Test do
     |> Enum.with_index()
     |> Enum.each(fn {string, index} ->
       status = Couch.post("/#{db_name}", query: [w: 3], body: %{"_id" => Integer.to_string(index), "text" => string}).status_code
-      assert status == 201
+      assert status in [201, 202]
     end)
 
     texts


[couchdb] 01/06: Port UTF8 js test suite to elixir

Posted by ja...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

jan pushed a commit to branch multi/elixir-3
in repository https://gitbox.apache.org/repos/asf/couchdb.git

commit 9ea9fa01c8c4218a90eaf8dd74ec5e2f78613e08
Author: Alessio Biancalana <do...@gmail.com>
AuthorDate: Mon Oct 7 12:02:33 2019 +0200

    Port UTF8 js test suite to elixir
---
 test/elixir/README.md          |  2 +-
 test/elixir/test/utf8_test.exs | 65 ++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 66 insertions(+), 1 deletion(-)

diff --git a/test/elixir/README.md b/test/elixir/README.md
index 7f13d8a..c4aec6d 100644
--- a/test/elixir/README.md
+++ b/test/elixir/README.md
@@ -95,7 +95,7 @@ X means done, - means partially
   - [ ] Port update_documents.js
   - [ ] Port users_db.js
   - [ ] Port users_db_security.js
-  - [ ] Port utf8.js
+  - [X] Port utf8.js
   - [X] Port uuids.js
   - [X] Port view_collation.js
   - [ ] Port view_collation_raw.js
diff --git a/test/elixir/test/utf8_test.exs b/test/elixir/test/utf8_test.exs
new file mode 100644
index 0000000..4153710
--- /dev/null
+++ b/test/elixir/test/utf8_test.exs
@@ -0,0 +1,65 @@
+defmodule UTF8Test do
+  use CouchTestCase
+
+  @moduletag :utf8
+
+  @moduledoc """
+  Test CouchDB UTF8 support
+  This is a port of the utf8.js test suite
+  """
+
+  @tag :with_db
+  test "UTF8 support", context do
+    db_name = context[:db_name]
+    texts = [
+      "1. Ascii: hello",
+      "2. Russian: На берегу пустынных волн",
+      "3. Math: ∮ E⋅da = Q,  n → ∞, ∑ f(i) = ∏ g(i),",
+      "4. Geek: STARGΛ̊TE SG-1",
+      "5. Braille: ⡌⠁⠧⠑ ⠼⠁⠒  ⡍⠜⠇⠑⠹⠰⠎ ⡣⠕⠌",
+      "6. null \u0000 byte",
+    ]
+    
+    texts
+    |> Enum.with_index()
+    |> Enum.each(fn {string, index} ->
+      status = Couch.post("/#{db_name}", query: [w: 3], body: %{"_id" => Integer.to_string(index), "text" => string}).status_code
+      assert status == 201
+    end)
+
+    texts
+    |> Enum.with_index()
+    |> Enum.each(fn {string, index} ->
+      resp = Couch.get("/#{db_name}/#{index}")
+      %{"_id" => id, "text" => text} = resp.body
+      assert resp.status_code == 200
+      assert Enum.at(texts, String.to_integer(id)) === text
+    end)
+
+    design_doc = %{
+      :_id => "_design/temp_utf8_support",
+      :language => "javascript",
+      :views => %{
+        :view => %{
+          :map => "function(doc) { emit(null, doc.text) }"
+        }
+      }
+    }
+
+    design_resp =
+      Couch.put(
+        "/#{db_name}/_design/temp_utf8_support",
+        body: design_doc,
+        query: %{w: 3}
+      )
+
+    assert design_resp.status_code in [201, 202]
+
+    %{"rows" => values} = Couch.get("/#{db_name}/_design/temp_utf8_support/_view/view").body
+    values
+    |> Enum.with_index()
+    |> Enum.each(fn {%{"value" => value}, index} ->
+      assert Enum.at(texts, index) === value
+    end)
+  end
+end


[couchdb] 03/06: Merge remote-tracking branch 'dottorblaster/update-elixir-test-suite-README' into port-utf8-tests-js-elixir

Posted by ja...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

jan pushed a commit to branch multi/elixir-3
in repository https://gitbox.apache.org/repos/asf/couchdb.git

commit 7a2df49b773f9ce3c1983077a98c5ba085822b85
Merge: b76a8b6 2db24b4
Author: Jan Lehnardt <ja...@apache.org>
AuthorDate: Sat Jan 4 17:54:41 2020 +0100

    Merge remote-tracking branch 'dottorblaster/update-elixir-test-suite-README' into port-utf8-tests-js-elixir
    
    * dottorblaster/update-elixir-test-suite-README:
      Update elixir test suite README.md with missing ported stuff

 test/elixir/README.md | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)