Skip to content

AssertNotEquals

Fails the current server workflow script when the values are equal.

myScript.AssertNotEquals(expected: any, actual: any, message?: string):void

Parameters

any expected
    The value that must differ.

any actual
    The value to verify.

string message optional
    Error text returned in the thrown JavaScript Error.

Remarks

Server workflow scripts only. Equality follows the same .NET normalization and comparison rules as AssertEquals().

Example

1
Script.AssertNotEquals("Closed", "Open", "The work item must remain open.");