summaryrefslogtreecommitdiff
path: root/spec/fixtures/lib
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-06-18 11:18:50 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2020-06-18 11:18:50 +0000
commit8c7f4e9d5f36cff46365a7f8c4b9c21578c1e781 (patch)
treea77e7fe7a93de11213032ed4ab1f33a3db51b738 /spec/fixtures/lib
parent00b35af3db1abfe813a778f643dad221aad51fca (diff)
downloadgitlab-ce-8c7f4e9d5f36cff46365a7f8c4b9c21578c1e781.tar.gz
Add latest changes from gitlab-org/gitlab@13-1-stable-ee
Diffstat (limited to 'spec/fixtures/lib')
-rw-r--r--spec/fixtures/lib/gitlab/metrics/dashboard/sample_dashboard.yml13
-rw-r--r--spec/fixtures/lib/gitlab/metrics/dashboard/schemas/dashboard.json4
-rw-r--r--spec/fixtures/lib/gitlab/metrics/dashboard/schemas/links.json9
-rw-r--r--spec/fixtures/lib/gitlab/metrics/dashboard/schemas/templating.json8
-rw-r--r--spec/fixtures/lib/gitlab/metrics/dashboard/schemas/text_variable_full_syntax.json12
-rw-r--r--spec/fixtures/lib/gitlab/metrics/dashboard/schemas/text_variable_options.json7
-rw-r--r--spec/fixtures/lib/gitlab/metrics/dashboard/schemas/variables.json12
7 files changed, 64 insertions, 1 deletions
diff --git a/spec/fixtures/lib/gitlab/metrics/dashboard/sample_dashboard.yml b/spec/fixtures/lib/gitlab/metrics/dashboard/sample_dashboard.yml
index b460a031486..5177de66fcf 100644
--- a/spec/fixtures/lib/gitlab/metrics/dashboard/sample_dashboard.yml
+++ b/spec/fixtures/lib/gitlab/metrics/dashboard/sample_dashboard.yml
@@ -1,5 +1,18 @@
dashboard: 'Test Dashboard'
priority: 1
+links:
+- title: Link 1
+ url: https://gitlab.com
+- title: Link 2
+ url: https://docs.gitlab.com
+templating:
+ variables:
+ text_variable_full_syntax:
+ label: 'Variable 1'
+ type: text
+ options:
+ default_value: 'default'
+ text_variable_simple_syntax: 'default value'
panel_groups:
- group: Group A
priority: 1
diff --git a/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/dashboard.json b/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/dashboard.json
index 5d779a323c2..259c41bf091 100644
--- a/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/dashboard.json
+++ b/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/dashboard.json
@@ -11,7 +11,9 @@
"panel_groups": {
"type": "array",
"items": { "$ref": "spec/fixtures/lib/gitlab/metrics/dashboard/schemas/panel_groups.json" }
- }
+ },
+ "templating": { "$ref": "spec/fixtures/lib/gitlab/metrics/dashboard/schemas/templating.json" },
+ "links": { "$ref": "spec/fixtures/lib/gitlab/metrics/dashboard/schemas/links.json" }
},
"additionalProperties": false
}
diff --git a/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/links.json b/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/links.json
new file mode 100644
index 00000000000..be180114052
--- /dev/null
+++ b/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/links.json
@@ -0,0 +1,9 @@
+{
+ "type": "array",
+ "required": ["url"],
+ "properties": {
+ "url": { "type": "string" },
+ "title": { "type": "string" }
+ },
+ "additionalProperties": false
+}
diff --git a/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/templating.json b/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/templating.json
new file mode 100644
index 00000000000..c82d2fcb02c
--- /dev/null
+++ b/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/templating.json
@@ -0,0 +1,8 @@
+{
+ "type": "object",
+ "required": ["variables"],
+ "properties": {
+ "variables": { "$ref": "variables.json" }
+ },
+ "additionalProperties": false
+}
diff --git a/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/text_variable_full_syntax.json b/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/text_variable_full_syntax.json
new file mode 100644
index 00000000000..f5090dc8c88
--- /dev/null
+++ b/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/text_variable_full_syntax.json
@@ -0,0 +1,12 @@
+{
+ "type": "object",
+ "required": [
+ "type", "options"
+ ],
+ "properties": {
+ "type": { "type": "string" },
+ "label": { "type": "string" },
+ "options": { "$ref": "text_variable_options.json" }
+ },
+ "additionalProperties": false
+}
diff --git a/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/text_variable_options.json b/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/text_variable_options.json
new file mode 100644
index 00000000000..ccb2e168fd1
--- /dev/null
+++ b/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/text_variable_options.json
@@ -0,0 +1,7 @@
+{
+ "type": "object",
+ "properties": {
+ "default_value": { "type": "string" }
+ },
+ "additionalProperties": false
+}
diff --git a/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/variables.json b/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/variables.json
new file mode 100644
index 00000000000..f3e0dd555a6
--- /dev/null
+++ b/spec/fixtures/lib/gitlab/metrics/dashboard/schemas/variables.json
@@ -0,0 +1,12 @@
+{
+ "type": "object",
+ "patternProperties": {
+ "^[a-zA-Z0-9_]*$": {
+ "anyOf": [
+ { "$ref": "text_variable_full_syntax.json" },
+ { "type": "string" }
+ ]
+ }
+ },
+ "additionalProperties": false
+}