-
Notifications
You must be signed in to change notification settings - Fork 129
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c7e6e2f
commit c9cf870
Showing
14 changed files
with
138 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -50,4 +50,35 @@ describe('Settings', function () { | |
assert.deepEqual(result, { 'test': 'abc' }); | ||
}); | ||
}); | ||
|
||
describe('testS3()', function () { | ||
it('Should send S3 connection test request', async function () { | ||
fetchMock.on({ | ||
method: 'POST', | ||
url: service.client.buildUrl('/api/settings/test/s3')+ '?q1=123', | ||
replyCode: 204, | ||
replyBody: true, | ||
}); | ||
|
||
const result = await service.testS3({ 'q1': 123 }); | ||
|
||
assert.isTrue(result); | ||
}); | ||
}); | ||
|
||
describe('testEmail()', function () { | ||
it('Should send a test email request', async function () { | ||
fetchMock.on({ | ||
method: 'POST', | ||
url: service.client.buildUrl('/api/settings/test/email')+ '?q1=123', | ||
body: { 'template': "abc", "email": "[email protected]" }, | ||
replyCode: 204, | ||
replyBody: true, | ||
}); | ||
|
||
const result = await service.testEmail("[email protected]", "abc", { "q1": 123 }); | ||
|
||
assert.isTrue(result); | ||
}); | ||
}); | ||
}); |