mirror of
https://github.com/logos-storage/logos-storage-contracts-eth.git
synced 2026-01-06 07:13:07 +00:00
14 lines
330 B
JavaScript
14 lines
330 B
JavaScript
|
|
export async function assertDeploymentRejectedWithCustomError(
|
||
|
|
customError,
|
||
|
|
deploymentPromise,
|
||
|
|
) {
|
||
|
|
const error = await expect(deploymentPromise).to.be.rejected
|
||
|
|
|
||
|
|
expect(error)
|
||
|
|
.to.have.property("message")
|
||
|
|
.that.contains(
|
||
|
|
customError,
|
||
|
|
`Expected error ${expectedError}, but got ${error.message}`,
|
||
|
|
)
|
||
|
|
}
|