Mike Gerwitz

Activist for User Freedom

aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorMike Gerwitz <mike.gerwitz@rtspecialty.com>2019-10-16 14:36:54 -0400
committerMike Gerwitz <mike.gerwitz@rtspecialty.com>2019-10-18 09:55:11 -0400
commite003abcd4bb72e9a4d5f93ad599ea81c1f4295fc (patch)
treec2d7cc21237820e2bc6e9ed23d9f9b6694580a9f /test
parentd8c065817f6483d4791611d624d66ff47efa2f41 (diff)
downloadliza-e003abcd4bb72e9a4d5f93ad599ea81c1f4295fc.tar.gz
liza-e003abcd4bb72e9a4d5f93ad599ea81c1f4295fc.tar.bz2
liza-e003abcd4bb72e9a4d5f93ad599ea81c1f4295fc.zip
Integrate TokenedDataApi into system
This changes the easejs interface for DataApi, which requires adding the param to everything. The TS interface was created in a previous commit and already contained this parameter. The idea is to remove the easejs interface in the future, but traits are a barrier to that atm. DocumentServer and controller demonstrate the mess that we have with regards to instantiating dependencies. This needs to change---DocumentServer itself was something that was started but never fully realized. It makes this incredibly confusing, difficult to follow, and complicates important error handling that ought to be taking place. It also discourages implementing additional dependencies. I'm not going to go through and provide a ChangeLog-style commit message for this commit. I'm too exhausted by this crap.
Diffstat (limited to 'test')
-rw-r--r--test/dapi/AutoRetryTest.js2
-rw-r--r--test/dapi/DummyDataApi.js4
-rw-r--r--test/dapi/format/JsonResponseTest.js2
-rw-r--r--test/server/service/RatingServiceSubmitNotifyTest.js2
4 files changed, 5 insertions, 5 deletions
diff --git a/test/dapi/AutoRetryTest.js b/test/dapi/AutoRetryTest.js
index 424babe..c6d12b3 100644
--- a/test/dapi/AutoRetryTest.js
+++ b/test/dapi/AutoRetryTest.js
@@ -282,7 +282,7 @@ function _createStub( err, resp )
given: null,
requests: 0,
- 'virtual public request': function( data, callback )
+ 'virtual public request': function( data, callback, id )
{
this.given = data;
this.requests++;
diff --git a/test/dapi/DummyDataApi.js b/test/dapi/DummyDataApi.js
index a33c48b..038b184 100644
--- a/test/dapi/DummyDataApi.js
+++ b/test/dapi/DummyDataApi.js
@@ -59,9 +59,9 @@ module.exports = Class( 'DummyDataApi' )
*
* @return {DataApi} self
*/
- 'virtual public request'( data, callback )
+ 'virtual public request'( data, callback, id )
{
- this._reqCallback( data, callback );
+ this._reqCallback( data, callback, id );
return this;
},
} );
diff --git a/test/dapi/format/JsonResponseTest.js b/test/dapi/format/JsonResponseTest.js
index 970ddeb..7f198c9 100644
--- a/test/dapi/format/JsonResponseTest.js
+++ b/test/dapi/format/JsonResponseTest.js
@@ -142,7 +142,7 @@ function _createStubbedDapi( err, resp )
{
given: null,
- 'virtual public request': function( data, callback )
+ 'virtual public request': function( data, callback, id )
{
this.given = data;
callback( err, resp );
diff --git a/test/server/service/RatingServiceSubmitNotifyTest.js b/test/server/service/RatingServiceSubmitNotifyTest.js
index e7bf4c6..1333eaf 100644
--- a/test/server/service/RatingServiceSubmitNotifyTest.js
+++ b/test/server/service/RatingServiceSubmitNotifyTest.js
@@ -127,7 +127,7 @@ describe( 'RatingServiceSubmitNotify', () =>
// warning: if an expectation fails, because of how
// RatingService handles errors, it will cause the test to
// _hang_ rather than throw the assertion error
- request( data, callback )
+ request( data, callback, id )
{
expect( given_request ).to.equal( request );
expect( data ).to.deep.equal( { quote_id: quote_id } );