51Degrees Pipeline .NET  4.1

51Degrees Pipeline for .NET

FiftyOne.Pipeline.JavaScript.Tests.JavaScriptBuilderElementTests Class Reference

Public Types

enum  ExceptionType {
  PropertyMissingException, PipelineDataException, InvalidCastException, KeyNotFoundException,
  Exception, None
}

Public Member Functions

void  Init ()
Initialise the test. More...
void  JavaScriptBuilderElement_JavaScript (string key, string property, object value)
This method tests the accessor functionality of the JavaScript include. More...
void  JavaScriptBuilder_VerifyUrl ()
Check that the callback URL is generated correctly. More...
void  JavaScriptBuilderElement_Promise (ExceptionType exceptionThrownByPromiseProperty, bool exceptionExpected)
Check that accessing the 'Promise' property works as intended in a range of scenarios More...
void  JavaScriptBuilderElement_DelayExecution (bool minify)
Verify that valid JavaScript is produced when there are delayed execution properties in the payload. More...

Member Function Documentation

◆ Init()

void FiftyOne.Pipeline.JavaScript.Tests.JavaScriptBuilderElementTests.Init ( )

Initialise the test.

◆ JavaScriptBuilder_VerifyUrl()

void FiftyOne.Pipeline.JavaScript.Tests.JavaScriptBuilderElementTests.JavaScriptBuilder_VerifyUrl ( )

Check that the callback URL is generated correctly.

TODO: Add more tests verifying URL if other parameters are set and if query parameters are in the evidence.

◆ JavaScriptBuilderElement_DelayExecution()

void FiftyOne.Pipeline.JavaScript.Tests.JavaScriptBuilderElementTests.JavaScriptBuilderElement_DelayExecution ( bool   minify )

Verify that valid JavaScript is produced when there are delayed execution properties in the payload.

◆ JavaScriptBuilderElement_JavaScript()

void FiftyOne.Pipeline.JavaScript.Tests.JavaScriptBuilderElementTests.JavaScriptBuilderElement_JavaScript ( string   key,
string   property,
object   value  
)

This method tests the accessor functionality of the JavaScript include.

For the supplied properties values, check that these properties can be accessed via the 'fod' object in the JavaScript include.

Parameters
key -
property -
value -

◆ JavaScriptBuilderElement_Promise()

void FiftyOne.Pipeline.JavaScript.Tests.JavaScriptBuilderElementTests.JavaScriptBuilderElement_Promise ( ExceptionType   exceptionThrownByPromiseProperty,
bool   exceptionExpected  
)

Check that accessing the 'Promise' property works as intended in a range of scenarios