finos/FDC3-conformance-framework

API methods should reject with an object of type Error

Closed this issue · 0 comments

When a failure occurs, an Error should be returned, with a defined string message. For example, with open:

If opening errors, it returns an Error with a string from the OpenError enumeration.

Currently our tests check whether a promise is rejected with a string message, see for example:

https://github.com/finos/FDC3-conformance-framework/blob/main/tests/src/test/fdc3.open.ts#L89

Notably container implementation seem to reject with string, e.g.

finos/FDC3-Sail#53
InteropIO/finsemble-seed#773

However, they should reject with an Error with the given string message.