mirror of
https://github.com/saltstack-formulas/cron-formula.git
synced 2025-07-03 17:32:28 +02:00
test(pillar): ensure special
is being tested as well
This commit is contained in:
parent
33f344c3ba
commit
951a95980a
@ -16,11 +16,15 @@ script:
|
|||||||
# yamllint disable rule:line-length
|
# yamllint disable rule:line-length
|
||||||
# Converge and verify the instance; `saltcheck` relies upon the `converge` as well
|
# Converge and verify the instance; `saltcheck` relies upon the `converge` as well
|
||||||
- bin/kitchen verify "${INSTANCE}"
|
- bin/kitchen verify "${INSTANCE}"
|
||||||
# If a `develop` instance, get the appropriate version of `saltcheck.py` (temporary)
|
# If a `develop` instance, get the appropriate version of `saltcheck.py` &
|
||||||
|
# `cron.py` (temporary)
|
||||||
- if [ ! -z $(echo "${INSTANCE}" | grep \\-develop-) ]; then
|
- if [ ! -z $(echo "${INSTANCE}" | grep \\-develop-) ]; then
|
||||||
bin/kitchen exec "${INSTANCE}" -c
|
bin/kitchen exec "${INSTANCE}" -c
|
||||||
"sudo curl -o \$(find /usr/lib/ -type d -name modules | grep packages/salt/modules)/saltcheck.py
|
"sudo curl -o \$(find /usr/lib/ -type d -name modules | grep packages/salt/modules)/saltcheck.py
|
||||||
https://raw.githubusercontent.com/myii/salt/fix/add-retcode/salt/modules/saltcheck.py";
|
https://raw.githubusercontent.com/myii/salt/fix/add-retcode/salt/modules/saltcheck.py";
|
||||||
|
bin/kitchen exec "${INSTANCE}" -c
|
||||||
|
"sudo curl -o \$(find /usr/lib/ -type d -name modules | grep packages/salt/modules)/cron.py
|
||||||
|
https://raw.githubusercontent.com/myii/salt/fix/add-retcode/salt/modules/cron.py";
|
||||||
fi
|
fi
|
||||||
# If a `develop` instance, run all of the `saltcheck` tests
|
# If a `develop` instance, run all of the `saltcheck` tests
|
||||||
- if [ ! -z $(echo "${INSTANCE}" | grep \\-develop-) ]; then
|
- if [ ! -z $(echo "${INSTANCE}" | grep \\-develop-) ]; then
|
||||||
|
@ -24,7 +24,8 @@ validate_cron.{{ task }}_exists:
|
|||||||
assertion_section: identifier
|
assertion_section: identifier
|
||||||
expected-return: {{ task }}
|
expected-return: {{ task }}
|
||||||
|
|
||||||
{%- for section in ['minute', 'hour', 'daymonth', 'month', 'dayweek', 'comment', 'special'] %}
|
{#- Note: `special` is `spec` in the module #}
|
||||||
|
{%- for section in ['minute', 'hour', 'daymonth', 'month', 'dayweek', 'comment', 'spec'] %}
|
||||||
{%- if section in task_options %}
|
{%- if section in task_options %}
|
||||||
validate_cron.{{ task }}_{{ section }}:
|
validate_cron.{{ task }}_{{ section }}:
|
||||||
module_and_function: cron.get_entry
|
module_and_function: cron.get_entry
|
||||||
|
@ -21,7 +21,7 @@ cron:
|
|||||||
minute: random
|
minute: random
|
||||||
hour: 1
|
hour: 1
|
||||||
task3:
|
task3:
|
||||||
type: absent
|
type: present
|
||||||
name: echo task3 > /tmp/test3
|
name: echo task3 > /tmp/test3
|
||||||
user: root
|
user: root
|
||||||
special: '@hourly'
|
special: '@hourly'
|
||||||
|
Loading…
x
Reference in New Issue
Block a user