Move all batch tests to their own directory
This commit is contained in:
parent
2bba1934ed
commit
2ac39b5748
2
Makefile
2
Makefile
@ -17,7 +17,7 @@ TEST_SUITE := $(shell find test/{acceptance,unit,integration} -name "*.js")
|
||||
TEST_SUITE_UNIT := $(shell find test/unit -name "*.js")
|
||||
TEST_SUITE_INTEGRATION := $(shell find test/integration -name "*.js")
|
||||
TEST_SUITE_ACCEPTANCE := $(shell find test/acceptance -name "*.js")
|
||||
TEST_SUITE_BATCH := $(shell find test -name "*job*.js")
|
||||
TEST_SUITE_BATCH := $(shell find test/*/batch -name "*.js")
|
||||
|
||||
test:
|
||||
@echo "***tests***"
|
||||
|
@ -1,16 +1,17 @@
|
||||
var assert = require('../support/assert');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
require('../../helper');
|
||||
var assert = require('../../support/assert');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var _ = require('underscore');
|
||||
var RedisPool = require('redis-mpool');
|
||||
var queue = require('queue-async');
|
||||
var batchFactory = require('../../batch');
|
||||
var batchFactory = require('../../../batch/index');
|
||||
|
||||
var JobPublisher = require('../../batch/job_publisher');
|
||||
var JobQueue = require('../../batch/job_queue');
|
||||
var JobBackend = require('../../batch/job_backend');
|
||||
var JobService = require('../../batch/job_service');
|
||||
var UserDatabaseMetadataService = require('../../batch/user_database_metadata_service');
|
||||
var JobCanceller = require('../../batch/job_canceller');
|
||||
var JobPublisher = require('../../../batch/job_publisher');
|
||||
var JobQueue = require('../../../batch/job_queue');
|
||||
var JobBackend = require('../../../batch/job_backend');
|
||||
var JobService = require('../../../batch/job_service');
|
||||
var UserDatabaseMetadataService = require('../../../batch/user_database_metadata_service');
|
||||
var JobCanceller = require('../../../batch/job_canceller');
|
||||
var metadataBackend = require('cartodb-redis')(redisUtils.getConfig());
|
||||
|
||||
describe('batch module', function() {
|
@ -1,12 +1,12 @@
|
||||
require('../helper');
|
||||
require('../../helper');
|
||||
|
||||
var assert = require('../support/assert');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
var server = require('../../app/server')();
|
||||
var assert = require('../../support/assert');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var server = require('../../../app/server')();
|
||||
var querystring = require('qs');
|
||||
var metadataBackend = require('cartodb-redis')(redisUtils.getConfig());
|
||||
var batchFactory = require('../../batch');
|
||||
var jobStatus = require('../../batch/job_status');
|
||||
var batchFactory = require('../../../batch/index');
|
||||
var jobStatus = require('../../../batch/job_status');
|
||||
|
||||
describe('Batch API callback templates', function () {
|
||||
|
@ -1,12 +1,12 @@
|
||||
require('../helper');
|
||||
require('../../helper');
|
||||
|
||||
var assert = require('../support/assert');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
var server = require('../../app/server')();
|
||||
var assert = require('../../support/assert');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var server = require('../../../app/server')();
|
||||
var querystring = require('qs');
|
||||
var metadataBackend = require('cartodb-redis')(redisUtils.getConfig());
|
||||
var batchFactory = require('../../batch');
|
||||
var jobStatus = require('../../batch/job_status');
|
||||
var batchFactory = require('../../../batch/index');
|
||||
var jobStatus = require('../../../batch/job_status');
|
||||
|
||||
describe('Batch API fallback job', function () {
|
||||
|
@ -12,11 +12,11 @@
|
||||
* HSET rails:users:vizzuality database_name cartodb_test_user_1_db
|
||||
*
|
||||
*/
|
||||
require('../helper');
|
||||
var JobController = require('../../app/controllers/job_controller');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
var server = require('../../app/server')();
|
||||
var assert = require('../support/assert');
|
||||
require('../../helper');
|
||||
var JobController = require('../../../app/controllers/job_controller');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var server = require('../../../app/server')();
|
||||
var assert = require('../../support/assert');
|
||||
var querystring = require('qs');
|
||||
|
||||
function payload(query) {
|
@ -12,11 +12,11 @@
|
||||
* HSET rails:users:vizzuality database_name cartodb_test_user_1_db
|
||||
*
|
||||
*/
|
||||
require('../helper');
|
||||
require('../../helper');
|
||||
|
||||
var server = require('../../app/server')();
|
||||
var assert = require('../support/assert');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
var server = require('../../../app/server')();
|
||||
var assert = require('../../support/assert');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var querystring = require('querystring');
|
||||
|
||||
describe('job module', function() {
|
@ -1,12 +1,12 @@
|
||||
require('../helper');
|
||||
require('../../helper');
|
||||
|
||||
var assert = require('../support/assert');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
var server = require('../../app/server')();
|
||||
var assert = require('../../support/assert');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var server = require('../../../app/server')();
|
||||
var querystring = require('qs');
|
||||
var metadataBackend = require('cartodb-redis')(redisUtils.getConfig());
|
||||
var batchFactory = require('../../batch');
|
||||
var jobStatus = require('../../batch/job_status');
|
||||
var batchFactory = require('../../../batch');
|
||||
var jobStatus = require('../../../batch/job_status');
|
||||
|
||||
describe('Batch API query timing', function () {
|
||||
|
@ -12,14 +12,14 @@
|
||||
* HSET rails:users:vizzuality database_name cartodb_test_user_1_db
|
||||
*
|
||||
*/
|
||||
require('../helper');
|
||||
require('../../helper');
|
||||
|
||||
var server = require('../../app/server')();
|
||||
var assert = require('../support/assert');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
var server = require('../../../app/server')();
|
||||
var assert = require('../../support/assert');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var querystring = require('querystring');
|
||||
var metadataBackend = require('cartodb-redis')(redisUtils.getConfig());
|
||||
var batchFactory = require('../../batch');
|
||||
var batchFactory = require('../../../batch/index');
|
||||
|
||||
describe('Use case 1: cancel and modify a done job', function () {
|
||||
var batch = batchFactory(metadataBackend, redisUtils.getConfig());
|
@ -12,14 +12,14 @@
|
||||
* HSET rails:users:vizzuality database_name cartodb_test_user_1_db
|
||||
*
|
||||
*/
|
||||
require('../helper');
|
||||
require('../../helper');
|
||||
|
||||
var server = require('../../app/server')();
|
||||
var assert = require('../support/assert');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
var server = require('../../../app/server')();
|
||||
var assert = require('../../support/assert');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var querystring = require('querystring');
|
||||
var metadataBackend = require('cartodb-redis')(redisUtils.getConfig());
|
||||
var batchFactory = require('../../batch');
|
||||
var batchFactory = require('../../../batch/index');
|
||||
|
||||
describe('Use case 10: cancel and modify a done multiquery job', function () {
|
||||
var batch = batchFactory(metadataBackend, redisUtils.getConfig());
|
@ -12,14 +12,14 @@
|
||||
* HSET rails:users:vizzuality database_name cartodb_test_user_1_db
|
||||
*
|
||||
*/
|
||||
require('../helper');
|
||||
require('../../helper');
|
||||
|
||||
var server = require('../../app/server')();
|
||||
var assert = require('../support/assert');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
var server = require('../../../app/server')();
|
||||
var assert = require('../../support/assert');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var querystring = require('querystring');
|
||||
var metadataBackend = require('cartodb-redis')(redisUtils.getConfig());
|
||||
var batchFactory = require('../../batch');
|
||||
var batchFactory = require('../../../batch/index');
|
||||
|
||||
describe('Use case 2: cancel a running job', function() {
|
||||
var batch = batchFactory(metadataBackend, redisUtils.getConfig());
|
@ -12,14 +12,14 @@
|
||||
* HSET rails:users:vizzuality database_name cartodb_test_user_1_db
|
||||
*
|
||||
*/
|
||||
require('../helper');
|
||||
require('../../helper');
|
||||
|
||||
var server = require('../../app/server')();
|
||||
var assert = require('../support/assert');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
var server = require('../../../app/server')();
|
||||
var assert = require('../../support/assert');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var querystring = require('querystring');
|
||||
var metadataBackend = require('cartodb-redis')(redisUtils.getConfig());
|
||||
var batchFactory = require('../../batch');
|
||||
var batchFactory = require('../../../batch/index');
|
||||
|
||||
describe('Use case 3: cancel a pending job', function() {
|
||||
var batch = batchFactory(metadataBackend, redisUtils.getConfig());
|
@ -12,14 +12,14 @@
|
||||
* HSET rails:users:vizzuality database_name cartodb_test_user_1_db
|
||||
*
|
||||
*/
|
||||
require('../helper');
|
||||
require('../../helper');
|
||||
|
||||
var server = require('../../app/server')();
|
||||
var assert = require('../support/assert');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
var server = require('../../../app/server')();
|
||||
var assert = require('../../support/assert');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var querystring = require('querystring');
|
||||
var metadataBackend = require('cartodb-redis')(redisUtils.getConfig());
|
||||
var batchFactory = require('../../batch');
|
||||
var batchFactory = require('../../../batch');
|
||||
|
||||
describe('Use case 4: modify a pending job', function() {
|
||||
var batch = batchFactory(metadataBackend, redisUtils.getConfig());
|
@ -12,14 +12,14 @@
|
||||
* HSET rails:users:vizzuality database_name cartodb_test_user_1_db
|
||||
*
|
||||
*/
|
||||
require('../helper');
|
||||
require('../../helper');
|
||||
|
||||
var server = require('../../app/server')();
|
||||
var assert = require('../support/assert');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
var server = require('../../../app/server')();
|
||||
var assert = require('../../support/assert');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var querystring = require('querystring');
|
||||
var metadataBackend = require('cartodb-redis')(redisUtils.getConfig());
|
||||
var batchFactory = require('../../batch');
|
||||
var batchFactory = require('../../../batch');
|
||||
|
||||
describe('Use case 5: modify a running job', function() {
|
||||
var batch = batchFactory(metadataBackend, redisUtils.getConfig());
|
@ -12,14 +12,14 @@
|
||||
* HSET rails:users:vizzuality database_name cartodb_test_user_1_db
|
||||
*
|
||||
*/
|
||||
require('../helper');
|
||||
require('../../helper');
|
||||
|
||||
var server = require('../../app/server')();
|
||||
var assert = require('../support/assert');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
var server = require('../../../app/server')();
|
||||
var assert = require('../../support/assert');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var querystring = require('querystring');
|
||||
var metadataBackend = require('cartodb-redis')(redisUtils.getConfig());
|
||||
var batchFactory = require('../../batch');
|
||||
var batchFactory = require('../../../batch');
|
||||
|
||||
describe('Use case 6: modify a done job', function() {
|
||||
var batch = batchFactory(metadataBackend, redisUtils.getConfig());
|
@ -12,14 +12,14 @@
|
||||
* HSET rails:users:vizzuality database_name cartodb_test_user_1_db
|
||||
*
|
||||
*/
|
||||
require('../helper');
|
||||
require('../../helper');
|
||||
|
||||
var server = require('../../app/server')();
|
||||
var assert = require('../support/assert');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
var server = require('../../../app/server')();
|
||||
var assert = require('../../support/assert');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var querystring = require('querystring');
|
||||
var metadataBackend = require('cartodb-redis')(redisUtils.getConfig());
|
||||
var batchFactory = require('../../batch');
|
||||
var batchFactory = require('../../../batch');
|
||||
|
||||
describe('Use case 7: cancel a job with quotes', function() {
|
||||
var batch = batchFactory(metadataBackend, redisUtils.getConfig());
|
@ -12,14 +12,14 @@
|
||||
* HSET rails:users:vizzuality database_name cartodb_test_user_1_db
|
||||
*
|
||||
*/
|
||||
require('../helper');
|
||||
require('../../helper');
|
||||
|
||||
var server = require('../../app/server')();
|
||||
var assert = require('../support/assert');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
var server = require('../../../app/server')();
|
||||
var assert = require('../../support/assert');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var querystring = require('querystring');
|
||||
var metadataBackend = require('cartodb-redis')(redisUtils.getConfig());
|
||||
var batchFactory = require('../../batch');
|
||||
var batchFactory = require('../../../batch');
|
||||
|
||||
describe('Use case 8: cancel a running multiquery job', function() {
|
||||
var batch = batchFactory(metadataBackend, redisUtils.getConfig());
|
@ -12,14 +12,14 @@
|
||||
* HSET rails:users:vizzuality database_name cartodb_test_user_1_db
|
||||
*
|
||||
*/
|
||||
require('../helper');
|
||||
require('../../helper');
|
||||
|
||||
var server = require('../../app/server')();
|
||||
var assert = require('../support/assert');
|
||||
var redisUtils = require('../support/redis_utils');
|
||||
var server = require('../../../app/server')();
|
||||
var assert = require('../../support/assert');
|
||||
var redisUtils = require('../../support/redis_utils');
|
||||
var querystring = require('querystring');
|
||||
var metadataBackend = require('cartodb-redis')(redisUtils.getConfig());
|
||||
var batchFactory = require('../../batch');
|
||||
var batchFactory = require('../../../batch');
|
||||
|
||||
describe('Use case 9: modify a pending multiquery job', function() {
|
||||
var batch = batchFactory(metadataBackend, redisUtils.getConfig());
|
Loading…
Reference in New Issue
Block a user