# automatically test all variables in a config file

**URL:** <https://forum.ansible.com/t/automatically-test-all-variables-in-a-config-file/23775>\
**Category:** Ansible Project\
**Created:** [February 21, 2017, 12:21am UTC](https://forum.ansible.com/t/automatically-test-all-variables-in-a-config-file/23775 "2017-02-21T00:21:33Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![sami.joseph](https://avatars.discourse-cdn.com/v4/letter/s/f6c823/32.png) [@sami.joseph](https://forum.ansible.com/u/sami.joseph)\
**Post date:** [February 21, 2017, 12:21am UTC](https://forum.ansible.com/t/automatically-test-all-variables-in-a-config-file/23775/1 "2017-02-21T00:21:33Z")

</div>

Hi,

I built an application that gets deployed using ansible, the ‘config’ file for my app has a lot of variables that are set in a YAML file.

Some examples of these variables:

1. Path to images
2. Number of VM instances to spin up
3. Number of CPU, Memory to use.  
…etc

I would like to test my deployment, with different variables (sort of fuzzing), and i wonder if there are any testing framework or tools out there, for this purpose.

Basically, I just want to exercise all these variables with different values.

Thanks,  
Sam

---

<div class="post-metadata">

**Author:** ![Dick\_Visser](https://avatars.discourse-cdn.com/v4/letter/d/d9b06d/32.png) [@Dick\_Visser](https://forum.ansible.com/u/Dick_Visser)\
**Post date:** [February 22, 2017, 9:30pm UTC](https://forum.ansible.com/t/automatically-test-all-variables-in-a-config-file/23775/2 "2017-02-22T21:30:57Z")

</div>

(I'll respond to only one of your three similar (fuzzing?) messages)

You can construct your vars using the random filter:

[http://docs.ansible.com/ansible/playbooks\_filters.html#random-number-filter](http://docs.ansible.com/ansible/playbooks_filters.html#random-number-filter)

DIck
