0

Is there a way we can share attributes between test kitchen suites

for eg:

Current setup

suite1:
  att1: "foo"

suite2:
  attr1: "foo"

New Setup

suites:
  attr1: "foo"
Jeetendra Pujari
  • 1,286
  • 2
  • 17
  • 31

1 Answers1

0

quoting kitchen documenation:

Each YAML file can contain ERB fragments, which you could use for selecting drivers, etc. based on which platform you’re currently running, or based off environment variables.

that implies that you can leverage ruby and set the values in a centralize place, then assign the values as you please.

for example:

# kitchen.yaml
<% my_attribute = "foo" %>

suite1:
  att1: <%= my_attribute %>

suite2:
  attr1: <%= my_attribute %>
Mr.
  • 9,429
  • 13
  • 58
  • 82