clinical_quality_language
clinical_quality_language copied to clipboard
Merge Message operator tests
Merged tests from engine/.../CqlErrorsAndMessagingOperatorsTest.cql into CqlErrorsAndMessagingOperatorsTest.xml.
Keeping the CQL library with the following define's:
- These are used in Java tests to test the engine messages (logs) produced by the
Messageoperator with the'Message','Warning', and'Trace'severities:
TestMessageInfo
TestMessageWarn
TestMessageTrace
- These are used in Java tests to test that the runtime throws when the severity is
'Error'(I also adjusted the Java tests for these define's so that they fail if the engine does not throw):
TestMessageError
TestErrorWithNullSource
TestErrorWithNullCode
TestErrorWithNullMessage
Note that TestErrorWithNullCondition defined as
define TestErrorWithNullCondition:
Message(1, null, '1', 'Error', 'This is a message')
is not supposed to throw because the spec says, "If condition is true, the message is generated. Otherwise, the operation only returns the results and performs no processing at all."
At the moment this is a draft and depends on https://github.com/cqframework/clinical_quality_language/issues/1401. Once I'm sure we can have Message calls with nulls without casts, I'll raise a corresponding PR to update cql-tests.
Formatting check succeeded!