declastruct-stripe-sdk
Version:
declarative control of stripe constructs, via declastruct
30 lines • 1.28 kB
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
const test_fns_1 = require("test-fns");
describe('sendInvoice', () => {
(0, test_fns_1.given)('a drafted invoice', () => {
(0, test_fns_1.when)('we request to charge', () => {
test_fns_1.then.todo('it should throw a bad request error', { because: 'the invoice has not been issued yet' }, () => { });
});
});
(0, test_fns_1.given)('an issued invoice', () => {
(0, test_fns_1.when)('we request to send', () => {
test_fns_1.then.todo('it should succeed');
});
});
(0, test_fns_1.given)('a paid invoice', () => {
(0, test_fns_1.when)('we request to charge', () => {
test_fns_1.then.todo('it should throw a bad request error', {
because: 'the invoice is already in a terminal state',
}, () => { });
});
});
(0, test_fns_1.given)('a voided invoice', () => {
(0, test_fns_1.when)('we request to charge', () => {
test_fns_1.then.todo('it should throw a bad request error', {
because: 'the invoice is already in a terminal state',
}, () => { });
});
});
});
//# sourceMappingURL=sendInvoice.integration.test.js.map