summaryrefslogtreecommitdiff
path: root/spec/frontend
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-03-30 18:08:07 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2020-03-30 18:08:07 +0000
commit2c72daf2f1744f2b8c8c6674c266907e9ef55558 (patch)
treee489b6e87557d3f6d8a94f2e7d4d47e633d646b5 /spec/frontend
parent4e9acbfba3682c552b3de707c535e6257ef41054 (diff)
downloadgitlab-ce-2c72daf2f1744f2b8c8c6674c266907e9ef55558.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/frontend')
-rw-r--r--spec/frontend/maintenance_mode_settings/components/app_spec.js42
1 files changed, 42 insertions, 0 deletions
diff --git a/spec/frontend/maintenance_mode_settings/components/app_spec.js b/spec/frontend/maintenance_mode_settings/components/app_spec.js
new file mode 100644
index 00000000000..a67bc63cfe1
--- /dev/null
+++ b/spec/frontend/maintenance_mode_settings/components/app_spec.js
@@ -0,0 +1,42 @@
+import { shallowMount } from '@vue/test-utils';
+import MaintenanceModeSettingsApp from '~/maintenance_mode_settings/components/app.vue';
+import { GlToggle, GlFormTextarea, GlButton } from '@gitlab/ui';
+
+describe('MaintenanceModeSettingsApp', () => {
+ let wrapper;
+
+ const createComponent = () => {
+ wrapper = shallowMount(MaintenanceModeSettingsApp);
+ };
+
+ afterEach(() => {
+ wrapper.destroy();
+ });
+
+ const findMaintenanceModeSettingsContainer = () => wrapper.find('article');
+ const findGlToggle = () => wrapper.find(GlToggle);
+ const findGlFormTextarea = () => wrapper.find(GlFormTextarea);
+ const findGlButton = () => wrapper.find(GlButton);
+
+ describe('template', () => {
+ beforeEach(() => {
+ createComponent();
+ });
+
+ it('renders the Maintenance Mode Settings container', () => {
+ expect(findMaintenanceModeSettingsContainer().exists()).toBe(true);
+ });
+
+ it('renders the GlToggle', () => {
+ expect(findGlToggle().exists()).toBe(true);
+ });
+
+ it('renders the GlFormTextarea', () => {
+ expect(findGlFormTextarea().exists()).toBe(true);
+ });
+
+ it('renders the GlButton', () => {
+ expect(findGlButton().exists()).toBe(true);
+ });
+ });
+});