Click or drag to resize

ITestApiCreate(String, Object, String) Method

Persist a Data Object in the database. The system will automatically clean up the data object after the test is finished.

Namespace: Casewhere.Runtime.DSL.Api
Assembly: Casewhere.Runtime (in Casewhere.Runtime.dll) Version: 2.8.5.0
Syntax
C#
string Create(
	string dataClassName,
	Object data,
	string registerName = null
)

Parameters

dataClassName  String
Data Class name
data  Object
Data Object to be added.
registerName  String  (Optional)
Optional name of sharing data stored in memory. If null, the data object will be added to the case of the workflow.

Return Value

String
Id of the added Data Object.
Example
C#
var testApi = ctx.Use<ITestApi>();
var doId = testApi.Create("TestSampleData", new 
{
    Name = "Tester",
    IsActive = true,
    Level = 1
});
See Also