Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2022-11-03 21:11:17 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2022-11-03 21:11:17 +0300
commit44434461b3c58336624125b5ab002e7200e4a208 (patch)
treecef2ea602e94abd9c1ef6ee77b6988c4c85475b7 /spec/frontend/flash_spec.js
parente6fa9529b4922a4c552e8908a2929ff995e8b53d (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/frontend/flash_spec.js')
-rw-r--r--spec/frontend/flash_spec.js14
1 files changed, 14 insertions, 0 deletions
diff --git a/spec/frontend/flash_spec.js b/spec/frontend/flash_spec.js
index a809bf248bf..a105b0b165c 100644
--- a/spec/frontend/flash_spec.js
+++ b/spec/frontend/flash_spec.js
@@ -193,6 +193,20 @@ describe('Flash', () => {
);
});
+ describe('with title', () => {
+ const mockTitle = 'my title';
+
+ it('shows title and message', () => {
+ createAlert({
+ title: mockTitle,
+ message: mockMessage,
+ });
+
+ const text = document.querySelector('.flash-container').textContent.trim();
+ expect(text).toBe(`${mockTitle} ${mockMessage}`);
+ });
+ });
+
describe('with buttons', () => {
const findAlertAction = () => document.querySelector('.flash-container .gl-alert-action');