From 1c2e4e99167d4f3917ebe7e25674717b48cad888 Mon Sep 17 00:00:00 2001 From: Thomas Boerger Date: Mon, 28 Jan 2019 16:32:48 +0100 Subject: [PATCH] Add matrix legacy convert testdata --- .../legacy/internal/testdata/matrix_1.yml | 19 +++++ .../internal/testdata/matrix_1.yml.golden | 61 ++++++++++++++ .../legacy/internal/testdata/matrix_2.yml | 19 +++++ .../internal/testdata/matrix_2.yml.golden | 81 +++++++++++++++++++ 4 files changed, 180 insertions(+) create mode 100644 yaml/converter/legacy/internal/testdata/matrix_1.yml create mode 100644 yaml/converter/legacy/internal/testdata/matrix_1.yml.golden create mode 100644 yaml/converter/legacy/internal/testdata/matrix_2.yml create mode 100644 yaml/converter/legacy/internal/testdata/matrix_2.yml.golden diff --git a/yaml/converter/legacy/internal/testdata/matrix_1.yml b/yaml/converter/legacy/internal/testdata/matrix_1.yml new file mode 100644 index 0000000..77e3331 --- /dev/null +++ b/yaml/converter/legacy/internal/testdata/matrix_1.yml @@ -0,0 +1,19 @@ + +pipeline: + test: + image: golang:${GO_VERSION} + commands: + - go test -v ./... + +services: + redis: + image: redis:2.6 + +matrix: + include: + - GO_VERSION: 1.11 + REDIS_VERSION: 2.6 + - GO_VERSION: 1.10 + REDIS_VERSION: 2.6 + - GO_VERSION: 1.9 + REDIS_VERSION: 2.6 diff --git a/yaml/converter/legacy/internal/testdata/matrix_1.yml.golden b/yaml/converter/legacy/internal/testdata/matrix_1.yml.golden new file mode 100644 index 0000000..a78c2a6 --- /dev/null +++ b/yaml/converter/legacy/internal/testdata/matrix_1.yml.golden @@ -0,0 +1,61 @@ +--- +kind: pipeline +name: matrix-1 + +platform: + os: linux + arch: amd64 + +steps: +- name: test + pull: default + image: golang:1.11 + commands: + - go test -v ./... + +services: +- name: redis + pull: default + image: redis:2.6 + +--- +kind: pipeline +name: matrix-2 + +platform: + os: linux + arch: amd64 + +steps: +- name: test + pull: default + image: golang:1.10 + commands: + - go test -v ./... + +services: +- name: redis + pull: default + image: redis:2.6 + +--- +kind: pipeline +name: matrix-3 + +platform: + os: linux + arch: amd64 + +steps: +- name: test + pull: default + image: golang:1.9 + commands: + - go test -v ./... + +services: +- name: redis + pull: default + image: redis:2.6 + +... diff --git a/yaml/converter/legacy/internal/testdata/matrix_2.yml b/yaml/converter/legacy/internal/testdata/matrix_2.yml new file mode 100644 index 0000000..58ba6a5 --- /dev/null +++ b/yaml/converter/legacy/internal/testdata/matrix_2.yml @@ -0,0 +1,19 @@ + +pipeline: + test: + image: golang:${GO_VERSION} + commands: + - go test -v ./... + +services: + redis: + image: redis:${REDIS_VERSION} + +matrix: + GO_VERSION: + - 1.11 + - 1.10 + + REDIS_VERSION: + - 2.6 + - 2.8 diff --git a/yaml/converter/legacy/internal/testdata/matrix_2.yml.golden b/yaml/converter/legacy/internal/testdata/matrix_2.yml.golden new file mode 100644 index 0000000..609709d --- /dev/null +++ b/yaml/converter/legacy/internal/testdata/matrix_2.yml.golden @@ -0,0 +1,81 @@ +--- +kind: pipeline +name: matrix-1 + +platform: + os: linux + arch: amd64 + +steps: +- name: test + pull: default + image: golang:1.11 + commands: + - go test -v ./... + +services: +- name: redis + pull: default + image: redis:2.6 + +--- +kind: pipeline +name: matrix-2 + +platform: + os: linux + arch: amd64 + +steps: +- name: test + pull: default + image: golang:1.11 + commands: + - go test -v ./... + +services: +- name: redis + pull: default + image: redis:2.8 + +--- +kind: pipeline +name: matrix-3 + +platform: + os: linux + arch: amd64 + +steps: +- name: test + pull: default + image: golang:1.10 + commands: + - go test -v ./... + +services: +- name: redis + pull: default + image: redis:2.6 + +--- +kind: pipeline +name: matrix-4 + +platform: + os: linux + arch: amd64 + +steps: +- name: test + pull: default + image: golang:1.10 + commands: + - go test -v ./... + +services: +- name: redis + pull: default + image: redis:2.8 + +...