Skip to content
Permalink
Browse files

PRESIDECMS-1697 - Updating mocks to include the useCache=false parameter

  • Loading branch information...
Niall O'Doherty
Niall O'Doherty committed Oct 1, 2019
1 parent ca8ca17 commit 95e7c5a2ee11d708130504152a3d8290130c7112
Showing with 4 additions and 3 deletions.
  1. +4 −3 support/tests/integration/api/email/EmailTemplateServiceTest.cfc
@@ -655,7 +655,7 @@ component extends="resources.HelperObjects.PresideBddTestCase" {

for( var r in mockResult ) { expected = r; }

mockTemplateDao.$( "selectData" ).$args( id=template, allowDraftVersions=false, fromversionTable=false, specificVersion=0 ).$results( mockResult );
mockTemplateDao.$( "selectData" ).$args( id=template, allowDraftVersions=false, fromversionTable=false, specificVersion=0, useCache=false ).$results( mockResult );

expect( service.getTemplate( template ) ).toBe( expected );
} );
@@ -668,7 +668,7 @@ component extends="resources.HelperObjects.PresideBddTestCase" {

for( var r in mockResult ) { expected = r; }

mockTemplateDao.$( "selectData" ).$args( id=template, allowDraftVersions=true, fromversionTable=true, specificVersion=0 ).$results( mockResult );
mockTemplateDao.$( "selectData" ).$args( id=template, allowDraftVersions=true, fromversionTable=true, specificVersion=0, useCache=false ).$results( mockResult );

expect( service.getTemplate( id=template, allowDrafts=true ) ).toBe( expected );
} );
@@ -687,6 +687,7 @@ component extends="resources.HelperObjects.PresideBddTestCase" {
, allowDraftVersions = false
, fromversionTable = true
, specificVersion = version
, useCache = false
).$results( mockResult );

expect( service.getTemplate( id=template, version=version ) ).toBe( expected );
@@ -705,7 +706,7 @@ component extends="resources.HelperObjects.PresideBddTestCase" {
, service_provider = mockBlueprint.service_provider
};

mockTemplateDao.$( "selectData" ).$args( id=template, allowDraftVersions=false, fromversionTable=false, specificVersion=0 ).$results( mockResult );
mockTemplateDao.$( "selectData" ).$args( id=template, allowDraftVersions=false, fromversionTable=false, specificVersion=0, useCache=false ).$results( mockResult );
mockBlueprintDao.$( "selectData" ).$args( id=mockResult.email_blueprint ).$results( mockBlueprint );

expect( service.getTemplate( template ) ).toBe( expected );

0 comments on commit 95e7c5a

Please sign in to comment.
You can’t perform that action at this time.