mirror of
https://github.com/logto-io/logto.git
synced 2024-12-16 20:26:19 -05:00
chore(connector): remove legacy Test passwordless template type use case (#5205)
This commit is contained in:
parent
ade9cf1dc7
commit
f15df4409f
7 changed files with 3 additions and 47 deletions
|
@ -36,15 +36,4 @@ describe('sendMessage()', () => {
|
|||
expect.anything()
|
||||
);
|
||||
});
|
||||
|
||||
it('throws if template is missing', async () => {
|
||||
const connector = await createConnector({ getConfig });
|
||||
await expect(
|
||||
connector.sendMessage({
|
||||
to: 'to@email.com',
|
||||
type: VerificationCodeType.Test,
|
||||
payload: { code: '1234' },
|
||||
})
|
||||
).rejects.toThrow();
|
||||
});
|
||||
});
|
||||
|
|
|
@ -73,15 +73,4 @@ describe('sendMessage()', () => {
|
|||
mockedConnectorConfig.accessKeySecret
|
||||
);
|
||||
});
|
||||
|
||||
it('throws if template is missing', async () => {
|
||||
const connector = await createConnector({ getConfig });
|
||||
await expect(
|
||||
connector.sendMessage({
|
||||
to: phoneTest,
|
||||
type: VerificationCodeType.Test,
|
||||
payload: { code: codeTest },
|
||||
})
|
||||
).rejects.toThrow();
|
||||
});
|
||||
});
|
||||
|
|
|
@ -53,15 +53,4 @@ describe('sendMessage()', () => {
|
|||
})
|
||||
);
|
||||
});
|
||||
|
||||
it('throws if template is missing', async () => {
|
||||
const connector = await createConnector({ getConfig });
|
||||
await expect(
|
||||
connector.sendMessage({
|
||||
to: 'to@email.com',
|
||||
type: VerificationCodeType.Test,
|
||||
payload: { code: '1234' },
|
||||
})
|
||||
).rejects.toThrow();
|
||||
});
|
||||
});
|
||||
|
|
|
@ -26,7 +26,7 @@ export const mockedConfig: SendGridMailConfig = {
|
|||
fromEmail: 'noreply@logto.test.io',
|
||||
templates: [
|
||||
{
|
||||
usageType: 'Test',
|
||||
usageType: 'Generic',
|
||||
type: ContextType.Text,
|
||||
subject: 'Logto Test Template',
|
||||
content: 'This is for testing purposes only. Your verification code is {{code}}.',
|
||||
|
|
|
@ -10,7 +10,7 @@ export const mockedConfig: SmsAeroConfig = {
|
|||
senderName: mockedSenderName,
|
||||
templates: [
|
||||
{
|
||||
usageType: 'Test',
|
||||
usageType: 'Generic',
|
||||
content: 'This is for testing purposes only. Your verification code is {{code}}.',
|
||||
},
|
||||
],
|
||||
|
|
|
@ -63,15 +63,4 @@ describe('sendMessage()', () => {
|
|||
})
|
||||
);
|
||||
});
|
||||
|
||||
it('throws if template is missing', async () => {
|
||||
const connector = await createConnector({ getConfig });
|
||||
await expect(
|
||||
connector.sendMessage({
|
||||
to: phoneTest,
|
||||
type: VerificationCodeType.Test,
|
||||
payload: { code: codeTest },
|
||||
})
|
||||
).rejects.toThrow();
|
||||
});
|
||||
});
|
||||
|
|
|
@ -10,7 +10,7 @@ export const mockedConfig: TwilioSmsConfig = {
|
|||
fromMessagingServiceSID: mockedFromMessagingServiceSID,
|
||||
templates: [
|
||||
{
|
||||
usageType: 'Test',
|
||||
usageType: 'Generic',
|
||||
content: 'This is for testing purposes only. Your verification code is {{code}}.',
|
||||
},
|
||||
],
|
||||
|
|
Loading…
Reference in a new issue