Commit Graph

637 Commits

Author SHA1 Message Date
Daniel García Aubert
2b86abbeba Please, jshint 2019-05-28 19:30:17 +02:00
Daniel García Aubert
6676260b17 Implement a throttler stream to check input data speed 2019-05-28 19:24:29 +02:00
Daniel García Aubert
fbc958f8e1 Materialize table creation as test setup 2019-05-16 12:17:24 +02:00
Daniel García Aubert
2e2e233b68 Use 'bunyan' logger instead of 'debug' to log debug messages 2019-04-04 14:31:41 +02:00
Simon Martín
23149ce7bf remving length test 2019-02-28 16:55:01 +01:00
Simon Martín
9cf68f2f16 Batch API Queries with fallbacks tests 2019-02-28 16:02:34 +01:00
Simon Martín
52e4dfa728 using the new TYPES 2019-02-28 11:49:05 +01:00
Simon Martín
d5470ac556 testing config parameters usage 2019-02-27 12:50:23 +01:00
Simon Martín
c53ed67252 typo 2019-02-27 11:57:36 +01:00
Simon Martín
1c6cb293d4 testing log middleware 2019-02-27 10:09:08 +01:00
Simon Martín
cd6bbaddab remove 'only' 2019-02-26 16:29:07 +01:00
Simon Martín
157786a7bd batch queries tests 2019-02-26 16:22:39 +01:00
Simon Martín
9f4adbc3de Handle query middleware failing tests 2019-02-26 15:43:14 +01:00
Simon Martín
9ab3f71f03 Handle query middleware acceptance test 2019-02-26 15:37:03 +01:00
Simon Martín
799b767505 remove old query log system 2019-02-26 13:58:01 +01:00
Simon Martín
60702faa57 adding Authorization to Access-Control-Allow-Headers 2019-01-10 15:55:08 +01:00
Raul Marin
03701ae695 Set platform limits message on streaming responses too 2019-01-02 16:21:33 +01:00
Raul Marin
7eb412cf59 Test: Accept PG11 error messages 2019-01-02 16:21:33 +01:00
Rafa de la Torre
2f8357ee4f Properly mock Date.now() for tests 2018-12-11 11:50:53 +01:00
Simon Martín
4dbd4d8b80 tests ensuring cancel query with Quota exceeded or max POST size 2018-11-29 18:42:04 +01:00
Daniel García Aubert
a616982ec3 Use strict mode 2018-10-24 15:42:33 +02:00
Rafa de la Torre
a927a6993a Add a test to reproduce the issue w/ COPY TO #590 2018-09-17 16:46:09 +02:00
Simon Martín
cc9e6eae43 new tmpDir more verbose 2018-08-30 15:10:43 +02:00
Simon Martín
a0db81369a forgotten .only (shame on me) 2018-08-30 15:06:07 +02:00
Simon Martín
3468353876 ensure tmpDir test 2018-08-30 12:50:50 +02:00
Simon Martín
e008eb66df remove only 2018-08-10 14:40:23 +02:00
Simon Martín
c0ea5be5d3 Improve gzip error message 2018-08-10 14:38:50 +02:00
Rafa de la Torre
8a76df8884 Fix for unhandled gunzip/zlib errors #528 2018-08-10 12:37:49 +02:00
Rafa de la Torre
6193f58dd2 Test for faulty gzip headers scenario 2018-08-10 12:15:31 +02:00
Rafa de la Torre
7277143c27 Merge remote-tracking branch 'origin/master' into 521-test-robustness-pgbouncer 2018-07-25 15:07:55 +02:00
Rafa de la Torre
75f25a6c02 Test for the max POST size 2018-07-23 16:58:05 +02:00
Rafa de la Torre
a8e538aba4 Test for COPY TO and DB quota 2018-07-23 16:20:15 +02:00
Rafa de la Torre
7b405cee5d Add test for DB quota exceeded 2018-07-23 16:14:10 +02:00
Rafa de la Torre
153ae3ea3d Fix test: increase timeout for DB quota middleware
In order to give the DB quota middleware a chance of getting executed,
increase the 1 ms timeout to 10 ms. This is short but enough, as the
quota mocks are constant functions.
2018-07-23 15:36:13 +02:00
Rafa de la Torre
fdab0136e6 Fix copy/paste test 2018-07-20 16:17:44 +02:00
Rafa de la Torre
ce409b4925 Fix typo in test describe 2018-07-20 16:09:10 +02:00
Rafa de la Torre
0f8e1f43c4 Add more tests for copy_timeout 2018-07-20 15:57:36 +02:00
Rafa de la Torre
682d7e6812 Simplify timeout tests 2018-07-20 15:38:20 +02:00
Rafa de la Torre
f437df9045 Fix timeout tests 2018-07-20 15:33:12 +02:00
Rafa de la Torre
20d1db78dc Helper to reset pgbouncer connections #521
This sends a PAUSE and RESUME to pgbouncer (in case there's one) before
and after executing tests, to make sure new connections are established
in the tests.

This may be especially important when role or session settings are
modified in the DB (same happens in prod, BTW).
2018-07-19 18:43:17 +02:00
Eneko Lakasta
1bf8a06ec2 Rephrase error message 2018-06-29 13:19:32 +02:00
Eneko Lakasta
3c603d65c8 update tests messages accordingly 2018-06-27 16:27:10 +02:00
Simon Martín
e7750eb4c8 undo remove line 2018-06-21 16:36:21 +02:00
Simon Martín
7e593bb3c9 copy to tests: cancel query with only 1 connection 2018-06-21 13:06:38 +02:00
Simon Martín
f46669fd4f details from merge 2018-06-21 12:25:19 +02:00
Simon Martín
6955d254f8 Merge branch 'master' into pgcopy-stream-refactor2-dgaubert 2018-06-21 12:19:16 +02:00
Simon Martín
dd088215c1 unify client disconnect timeout 2018-06-20 19:03:23 +02:00
Simon Martín
030a8f1ef4 checking connection reuse properly 2018-06-20 19:02:34 +02:00
Simon Martín
50da363ae0 improving name dropTableOptions 2018-06-20 18:39:17 +02:00
Simon Martín
20e43f6029 ensuring query cancelation in copy from 2018-06-20 14:43:50 +02:00
Simon Martín
84c43344e4 jshgint happy 2018-06-20 13:18:32 +02:00
Simon Martín
c37ea82c0e updating copyto test making them independent 2018-06-20 11:12:19 +02:00
Simon Martín
5021c8d466 making copy test independent 2018-06-20 11:08:41 +02:00
Simon Martín
16c2fd728f js hint happy 2018-06-20 10:48:03 +02:00
Simon Martín
81e33b632d Merge branch 'master' into copyto-cancel-test 2018-06-19 15:50:46 +02:00
Daniel García Aubert
258baa3792 Remove test filter 2018-06-18 10:56:14 +02:00
Daniel García Aubert
bd499b88e5 Add tests to check copyto cancel works properly 2018-06-18 10:53:44 +02:00
Simon Martín
7dec3f4e95 jshint happy 2018-06-15 13:47:37 +02:00
Simon Martín
d4e03303f9 done after response end in test copy to 2018-06-14 18:25:38 +02:00
Simon Martín
0757d11bd0 more deterministic tests when client disconnects 2018-06-14 18:10:41 +02:00
Simon Martín
34c0c5c738 removing console log 2018-06-14 10:48:00 +02:00
Simon Martín
2fa5e7b84a grouping all copy related tests in a describe 2018-06-14 10:44:57 +02:00
Simon Martín
d67cf2f7d5 removing only 2018-06-12 16:53:37 +02:00
Simon Martín
a00891ff98 grouping all the copy tests in one describe 2018-06-12 16:46:54 +02:00
Simon Martín
8a15b2f8d1 Merge branch 'master' into pgcopy-stream-refactor2 2018-06-12 15:21:28 +02:00
Rafa de la Torre
fc12917938 Please jshint 2018-06-11 19:26:40 +02:00
Rafa de la Torre
b1073dc401 Test for the COPY FROM + disconnect 2018-06-11 19:17:23 +02:00
Rafa de la Torre
66664de286 Make the test far more robust 2018-06-11 19:04:33 +02:00
Rafa de la Torre
1417dedfd3 Final touches for client disconnect test 2018-06-11 18:45:12 +02:00
Rafa de la Torre
62fe8abd0a A much cleaner test 2018-06-11 18:38:18 +02:00
Rafa de la Torre
4b6ee133df Mess a little with the timeouts 2018-06-11 18:18:44 +02:00
Rafa de la Torre
52590faeac Add a test for client disconnection scenarios 2018-06-11 17:28:53 +02:00
Simon Martín
1174499dcf Merge branch 'master' into pgcopy-stream 2018-06-11 14:38:52 +02:00
Simon Martín
8e8ccc9c67 removing old metrics in copy 2018-06-08 13:33:17 +02:00
Eneko Lakasta
03e484c5da FIX tests. Create jobs should return 403 if auth fails 2018-06-05 15:49:15 +02:00
Eneko Lakasta
06282b61fb refactor authenticatedRequest to masterRequest 2018-06-05 13:22:43 +02:00
Simon Martín
a8ccacbc09 size returns to unzipped 2018-06-05 13:16:01 +02:00
Rafa de la Torre
4022fb2967 Clean up before executing the copy suite
So that it can be executed saving a bit of setup/teardown time:

  test/run_tests.sh --nodrop --nocreate test/acceptance/copy-endpoints.js
2018-06-04 15:46:52 +02:00
Simon Martín
b05ded92aa db connections usage test 2018-06-01 11:26:28 +02:00
Eneko Lakasta
cf8bf6e5e6 get DB configuration from job instead from metadata in Job Canceller 2018-05-30 17:36:55 +02:00
Eneko Lakasta
60beea19d7 add default public fallback tests 2018-05-30 13:28:50 +02:00
Eneko Lakasta
6e3eb8ef28 Fix test: add auth params to job 2018-05-30 11:48:15 +02:00
Simon Martín
5f8533bf99 get the size gzipped 2018-05-29 16:19:06 +02:00
Simon Martín
3cf28bb7ff jshint happy 2018-05-25 18:50:56 +02:00
Simon Martín
22caa049ee StreamCopyMetrics 2018-05-25 18:47:41 +02:00
Simon Martín
e2bba967f9 handling copyto errors 2018-05-24 19:48:24 +02:00
Simon Martín
3d8f45afd8 going red 2018-05-24 19:08:35 +02:00
Simon Martín
5ba7dca79c copyfrom metrics to kibana 2018-05-23 10:30:37 +02:00
Paul Ramsey
8dd1d5babf Try and quiet multipart query 2018-05-22 15:24:19 -04:00
Paul Ramsey
a4654f82b2 Merge branch 'pgcopy-stream' of github.com:CartoDB/CartoDB-SQL-API into pgcopy-stream-q 2018-05-22 10:37:50 -04:00
Paul Ramsey
ed696a96ec Merge branch 'pgcopy-stream' of github.com:CartoDB/CartoDB-SQL-API into pgcopy-stream-q 2018-05-22 10:23:04 -04:00
Simon Martín
bfeea58268 copyFrom metrics to statsd tests 2018-05-22 16:07:04 +02:00
Simon Martín
30cb88c3f9 test for copyto without sql 2018-05-22 15:56:04 +02:00
Simon Martín
e347985465 changing query parameter name from sql to q
unify query validatrion
2018-05-22 15:42:57 +02:00
Simon Martín
79383bb119 removing only 2018-05-22 11:57:10 +02:00
Simon Martín
433bd01c27 copyto metrics 2018-05-22 11:54:10 +02:00
Simon Martín
81be15fbc3 adding format to copy metrics 2018-05-21 19:13:44 +02:00
Paul Ramsey
64fc0c32e3 Change from 'sql' as query parameter to 'q', aping existing sql api 2018-05-21 07:47:16 -07:00
Eneko Lakasta
e85994293b remove fallback tests and refactor some http errors 403 -> 401 2018-05-17 17:13:00 +02:00
Simon Martín
d970742860 removing uneeded param 2018-05-11 14:10:52 +02:00