Skip to content

Instantly share code, notes, and snippets.

@kerasai
Created July 17, 2015 17:19
Show Gist options
  • Save kerasai/7b5bab855e4e69e3d3b5 to your computer and use it in GitHub Desktop.
Save kerasai/7b5bab855e4e69e3d3b5 to your computer and use it in GitHub Desktop.
Feature: As a user of the drupal-extension and drupal driver
I want to properly set term references on content
So that I may reliably conduct tests
@api
Scenario: Duplicate terms in different vocabs
Given "category" terms:
| name |
| A |
| B |
| C |
And "tags" terms:
| name |
| A |
| B |
When "post" content:
| title | field_category | field_tags |
| A Post | A | B |
Then "A Post" field "field_category" values should be from "category" vocabulary
And "A Post" field "field_tags" values should be from "tags" vocabulary
@kerasai
Copy link
Author

kerasai commented Jul 17, 2015

Assumes the following:

  • "category" and "tags" vocabularies
  • "post" node type
  • "field_category" term/entity ref field on "post" nodes configured to use "category" vocab
  • "field_tags" term/entity ref field on "post" nodes configured to use "tags" vocab

Custom step: https://gist.github.com/kerasai/ddb24449fe090b7717f3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment