Add a random component to state machine name in aws_step_functions_st… (#64476)

* Add a random component to state machine name in aws_step_functions_state_machine testsuite

* Pick a random number from a bigger set to avoid conflicts between parallel runs

Co-Authored-By: Matt Clay <matt@mystile.com>
This commit is contained in:
Prasad Katti 2019-11-14 08:37:55 -08:00 committed by Matt Clay
parent 81b334bcaf
commit 9b0cdad4d4
2 changed files with 6 additions and 1 deletions

View file

@ -1,2 +1,3 @@
state_machine_name: "{{ resource_prefix }}_step_functions_state_machine_ansible_test"
# the random_num is generated in a set_fact task at the start of the testsuite
state_machine_name: "{{ resource_prefix }}_step_functions_state_machine_ansible_test_{{ random_num }}"
step_functions_role_name: "ansible-test-sts-{{ resource_prefix }}-step_functions-role"

View file

@ -29,6 +29,10 @@
# ==== Tests ===================================================
- name: Create a random component for state machine name
set_fact:
random_num: "{{ 999999999 | random }}"
- name: Create a new state machine -- check_mode
aws_step_functions_state_machine:
name: "{{ state_machine_name }}"