From 270ea1b223efd915daa046940022dba5e94f5413 Mon Sep 17 00:00:00 2001 From: Imran Iqbal Date: Wed, 23 Oct 2019 05:21:41 +0100 Subject: [PATCH] feat(openvpn): implement Windows testing using `kitchen-vagrant` * https://github.com/saltstack-formulas/openvpn-formula/pull/112 --- ssf/defaults.yaml | 4 ++-- ssf/files/default/inspec/inspec.yml | 2 +- ssf/files/tofs_openvpn-formula/Gemfile | 13 +++++++++++++ ssf/formulas.yaml | 16 +++++++++++++++- 4 files changed, 31 insertions(+), 4 deletions(-) create mode 100644 ssf/files/tofs_openvpn-formula/Gemfile diff --git a/ssf/defaults.yaml b/ssf/defaults.yaml index 840e2a4a..c7f5856e 100644 --- a/ssf/defaults.yaml +++ b/ssf/defaults.yaml @@ -22,8 +22,8 @@ ssf_node_anchors: # An alternative method could be to use: # `git describe --abbrev=0 --tags` # yamllint disable rule:line-length - title: 'feat(semantic-release): implement for this formula' - body: '* Automated using https://github.com/myii/ssf-formula/pull/79' + title: 'feat(kitchen): implement Windows testing using `kitchen-vagrant`' + body: '* Checked using https://github.com/myii/ssf-formula/pull/81' # yamllint enable rule:line-length github: owner: 'saltstack-formulas' diff --git a/ssf/files/default/inspec/inspec.yml b/ssf/files/default/inspec/inspec.yml index ba405577..344642c7 100644 --- a/ssf/files/default/inspec/inspec.yml +++ b/ssf/files/default/inspec/inspec.yml @@ -26,5 +26,5 @@ depends: {%- endif %} supports: {%- for platform in suite.inspec_yml.supports %} - - platform-name: {{ platform }} + - {{ 'platform-name' if platform != 'windows' else 'platform' }}: {{ platform }} {%- endfor %} diff --git a/ssf/files/tofs_openvpn-formula/Gemfile b/ssf/files/tofs_openvpn-formula/Gemfile new file mode 100644 index 00000000..caa85a0b --- /dev/null +++ b/ssf/files/tofs_openvpn-formula/Gemfile @@ -0,0 +1,13 @@ +# frozen_string_literal: true + +source 'https://rubygems.org' + +gem 'inspec', '~> 4.17.17' +gem 'kitchen-docker', '>= 2.9' +gem 'kitchen-inspec', '>= 1.1' +gem 'kitchen-salt', '>= 0.6.0' +gem 'rspec-retry' + +group :vagrant do + gem 'kitchen-vagrant' +end diff --git a/ssf/formulas.yaml b/ssf/formulas.yaml index 6af0d8eb..6040524e 100644 --- a/ssf/formulas.yaml +++ b/ssf/formulas.yaml @@ -997,6 +997,17 @@ ssf: inspec_yml: summary: >- Verify that the openvpn formula is setup and configured correctly + supports: + - debian + - ubuntu + - centos + - fedora + - opensuse + - suse + - freebsd + - amazon + - arch + - windows provisioner: pillars_from_files: - .sls: 'test/salt/pillar/default.sls' @@ -1013,7 +1024,10 @@ ssf: # - [fedora , 29 , 2018.3, 2, default] - [opensuse/leap, 15 , 2018.3, 2, default] - [centos , 6 , 2017.7, 2, default] - travis: *travis_do_not_use_single_job_for_linters + rubocop: + Cops: + Metrics/BlockLength: + Max: 36 semrel_files: *semrel_files_default php: context: