null+****@clear*****
null+****@clear*****
2012年 6月 21日 (木) 15:47:46 JST
SHIMODA Hiroshi 2012-06-21 15:47:46 +0900 (Thu, 21 Jun 2012) New Revision: 9a524c95fcac8f301bc79175446ac3abd621d720 https://github.com/groonga/gcs/commit/9a524c95fcac8f301bc79175446ac3abd621d720 Log: Update tests for api/batch.js Modified files: test/api-configuration.test.js Modified: test/api-configuration.test.js (+7 -3) =================================================================== --- test/api-configuration.test.js 2012-06-21 15:38:33 +0900 (14064ef) +++ test/api-configuration.test.js 2012-06-21 15:47:46 +0900 (1917589) @@ -102,9 +102,11 @@ suite('Configuration API', function() { var path = '/'; utils.get(path) .next(function(response) { + var message = 'An input parameter "Version" that is mandatory for ' + + 'processing the request is not supplied.';; var expected = { statusCode: 400, - body: 'API version must be given as the parameter "Version".' + body: createCommonErrorResponse('MissingParameter', message) }; assert.deepEqual(response, expected); done(); @@ -118,9 +120,11 @@ suite('Configuration API', function() { var path = '/?Version=2011-02-02'; utils.get(path) .next(function(response) { + var message = 'A bad or out-of-range value "' + version + + '" was supplied for the "Version" input parameter.'; var expected = { statusCode: 400, - body: 'API version "2011-02-02" is not supported.' + body: createCommonErrorResponse('InvalidParameterValue', message) }; assert.deepEqual(response, expected); done(); @@ -137,7 +141,7 @@ suite('Configuration API', function() { var message = 'The request is missing an action or operation parameter.'; var expected = { statusCode: 400, - body: createCommonErrorResponse('InvalidAction', message) + body: createCommonErrorResponse('MissingAction', message) }; assert.deepEqual(response, expected); done(); -------------- next part -------------- HTML$B$NE:IU%U%!%$%k$rJ]4I$7$^$7$?(B... Download