YUKI Hiroshi
null+****@clear*****
Thu Nov 15 16:39:31 JST 2012
YUKI Hiroshi 2012-11-15 16:39:31 +0900 (Thu, 15 Nov 2012) New Revision: b103e63f96da4eab0122e0e1f4410b3d3a6fb7d3 https://github.com/groonga/gcs/commit/b103e63f96da4eab0122e0e1f4410b3d3a6fb7d3 Log: Compare all responses in a scenario in a time Modified files: test/api-configuration.test.js Modified: test/api-configuration.test.js (+5 -2) =================================================================== --- test/api-configuration.test.js 2012-11-15 16:34:42 +0900 (10e8ef9) +++ test/api-configuration.test.js 2012-11-15 16:39:31 +0900 (e663793) @@ -1355,15 +1355,18 @@ suite('Configuration API', function() { var expectedResponsesDir = path.join(expectedResponsesBaseDir, scenarioBaseName); runner.on('end', function(event) { try { + var expectedResponses = []; + var actualResponses = []; scenario.requests.forEach(function(request) { var fileName = ScenarioRunner.toSafeName(request.name) + '.txt'; var expected = path.join(expectedResponsesDir, fileName); expected = fs.readFileSync(expected).toString(); expected = new ScenarioResponse(expected); + expectedResponses.push(expected.normalized); var actual = new ScenarioResponse(request.response); - assert.deepEqual(actual.normalized, - expected.normalized); + actualResponses.push(actual.normalized); }); + assert.deepEqual(actualResponses, expectedResponses); done(); } catch(error) { done(error); -------------- next part -------------- HTML����������������������������... 下载