Skip to content

Latest commit

 

History

History
42 lines (32 loc) · 912 Bytes

Variants.feature.md

File metadata and controls

42 lines (32 loc) · 912 Bytes
variants exampleContext
nw modem
ltem
LTE-M
nw modem
nbiot
NB-IoT
tracker
ltem nbiot
id
some-device
id
some-device

Using variants

Variants (defined in the frontmatter of a feature) can be used to run the same feature in different variants. For every entry in variants, the feature file is run.
The properties defined per variant are available in using the variant.<name> placeholder.

Scenario

Given network is ${variant.nw} and modem is ${variant.modem}

Alternative placeholders

These are useful in case variable placeholders need to be constructed.

Given network is <variant.nw> and modem is <variant.modem>

Nested variant placeholders

Given the placeholder <variant.nw> is embedded in another placeholder: ${tracker.<variant.nw>.id}/pgps/get

{
  "thingName": "${tracker.<variant.nw>.name}"
}