Fix tests
diff --git a/aptcacher/meta/sphinx.yml b/aptcacher/meta/sphinx.yml
index 85f8150..fe0426f 100644
--- a/aptcacher/meta/sphinx.yml
+++ b/aptcacher/meta/sphinx.yml
@@ -1,4 +1,4 @@
-{%- from "apt_cacher_ng/map.jinja" import server with context %}
+{%- from "aptcacher/map.jinja" import server with context %}
# Fill in documentation details
doc:
name: aptcacher
diff --git a/tests/pillar/compute_cluster.sls b/tests/pillar/compute_cluster.sls
deleted file mode 100644
index 6f03b6e..0000000
--- a/tests/pillar/compute_cluster.sls
+++ /dev/null
@@ -1,49 +0,0 @@
-nova:
- compute:
- version: liberty
- enabled: true
- virtualization: kvm
- heal_instance_info_cache_interval: 60
- vncproxy_url: openstack:6080
- bind:
- vnc_address: 127.0.0.1
- vnc_port: 6080
- vnc_name: 0.0.0.0
- database:
- engine: mysql
- host: 127.0.0.1
- port: 3306
- name: nova
- user: nova
- password: password
- identity:
- engine: keystone
- host: 127.0.0.1
- port: 35357
- user: nova
- password: password
- tenant: service
- message_queue:
- engine: rabbitmq
- host: 127.0.0.1
- port: 5672
- user: openstack
- password: password
- virtual_host: '/openstack'
- image:
- engine: glance
- host: 127.0.0.1
- port: 9292
- network:
- engine: neutron
- host: 127.0.0.1
- port: 9696
- cache:
- engine: memcached
- members:
- - host: 127.0.0.1
- port: 11211
- - host: 127.0.1.1
- port: 11211
- - host: 127.0.2.1
- port: 11211
diff --git a/tests/pillar/compute_single.sls b/tests/pillar/compute_single.sls
deleted file mode 100644
index 036a140..0000000
--- a/tests/pillar/compute_single.sls
+++ /dev/null
@@ -1,45 +0,0 @@
-nova:
- compute:
- version: liberty
- enabled: true
- virtualization: kvm
- heal_instance_info_cache_interval: 60
- vncproxy_url: openstack:6080
- bind:
- vnc_address: 127.0.0.1
- vnc_port: 6080
- vnc_name: 0.0.0.0
- database:
- engine: mysql
- host: 127.0.0.1
- port: 3306
- name: nova
- user: nova
- password: password
- identity:
- engine: keystone
- host: 127.0.0.1
- port: 35357
- user: nova
- password: password
- tenant: service
- message_queue:
- engine: rabbitmq
- host: 127.0.0.1
- port: 5672
- user: openstack
- password: password
- virtual_host: '/openstack'
- image:
- engine: glance
- host: 127.0.0.1
- port: 9292
- network:
- engine: neutron
- host: 127.0.0.1
- port: 9696
- cache:
- engine: memcached
- members:
- - host: 127.0.0.1
- port: 11211
diff --git a/tests/pillar/control_cluster.sls b/tests/pillar/control_cluster.sls
deleted file mode 100644
index 158f565..0000000
--- a/tests/pillar/control_cluster.sls
+++ /dev/null
@@ -1,48 +0,0 @@
-nova:
- controller:
- enabled: true
- networking: default
- version: liberty
- vncproxy_url: 127.0.0.1
- security_group: false
- dhcp_domain: novalocal
- scheduler_default_filters: "DifferentHostFilter,RetryFilter,AvailabilityZoneFilter,RamFilter,CoreFilter,DiskFilter,ComputeFilter,ComputeCapabilitiesFilter,ImagePropertiesFilter,ServerGroupAntiAffinityFilter,ServerGroupAffinityFilter"
- cpu_allocation_ratio: 16.0
- ram_allocation_ratio: 1.5
- bind:
- private_address: 127.0.0.1
- public_address: 127.0.0.1
- public_name: 127.0.0.1
- novncproxy_port: 6080
- database:
- engine: mysql
- host: 127.0.0.1
- port: 3306
- name: nova
- user: nova
- password: password
- identity:
- engine: keystone
- host: 127.0.0.1
- port: 35357
- user: nova
- password: password
- tenant: service
- message_queue:
- engine: rabbitmq
- host: 127.0.0.1
- port: 5672
- user: openstack
- password: password
- virtual_host: '/openstack'
- ha_queues: true
- glance:
- host:
- port: 9292
- network:
- engine: neutron
- host: 127.0.0.1
- port: 9696
- mtu: 1500
- metadata:
- password: metadata
diff --git a/tests/pillar/control_single.sls b/tests/pillar/control_single.sls
deleted file mode 100644
index 68c77b2..0000000
--- a/tests/pillar/control_single.sls
+++ /dev/null
@@ -1,52 +0,0 @@
-nova:
- controller:
- enabled: true
- networking: contrail
- version: liberty
- security_group: false
- vncproxy_url: 127.0.0.1
- dhcp_domain: novalocal
- scheduler_default_filters: "DifferentHostFilter,RetryFilter,AvailabilityZoneFilter,RamFilter,CoreFilter,DiskFilter,ComputeFilter,ComputeCapabilitiesFilter,ImagePropertiesFilter,ServerGroupAntiAffinityFilter,ServerGroupAffinityFilter"
- cpu_allocation_ratio: 16.0
- ram_allocation_ratio: 1.5
- bind:
- private_address: 127.0.0.1
- public_address: 127.0.0.1
- public_name: 127.0.0.1
- novncproxy_port: 6080
- database:
- engine: mysql
- host: localhost
- port: 3306
- name: nova
- user: nova
- password: password
- identity:
- engine: keystone
- host: 127.0.0.1
- port: 35357
- user: nova
- password: password
- tenant: service
- message_queue:
- engine: rabbitmq
- host: 127.0.0.1
- port: 5672
- user: openstack
- password: password
- virtual_host: '/openstack'
- glance:
- host: 127.0.0.1
- port: 9292
- network:
- engine: neutron
- host: 127.0.0.1
- port: 9696
- mtu: 1500
- metadata:
- password: password
- cache:
- engine: memcached
- members:
- - host: 127.0.0.1
- port: 11211
diff --git a/tests/pillar/server.sls b/tests/pillar/server.sls
new file mode 100644
index 0000000..d9733c2
--- /dev/null
+++ b/tests/pillar/server.sls
@@ -0,0 +1,16 @@
+aptcacher:
+ server:
+ enabled: true
+ bind:
+ address: 127.0.0.1
+ passthruurl:
+ - 'repos.influxdata.com'
+ - 'packagecloud.io'
+ - 'packagecloud-repositories.s3.dualstack.us-west-1.amazonaws.com'
+ - 'launchpad.net'
+ - 'apt.dockerproject.org'
+ passhthrupattern:
+ - '\.key$'
+ - '\.gpg$'
+ - '\.pub$'
+ - '\.jar$'
diff --git a/tests/pillar/single.yml b/tests/pillar/single.yml
deleted file mode 100644
index 9554a09..0000000
--- a/tests/pillar/single.yml
+++ /dev/null
@@ -1,5 +0,0 @@
-apt_cacher_ng:
- server:
- enabled: true
- bind:
- address: 0.0.0.0
diff --git a/tests/run_tests.sh b/tests/run_tests.sh
index 3f42101..ab84ffb 100755
--- a/tests/run_tests.sh
+++ b/tests/run_tests.sh
@@ -130,6 +130,13 @@
done
}
+real_run() {
+ for pillar in ${PILLARDIR}/*.sls; do
+ state_name=$(basename ${pillar%.sls})
+ salt_run --id=${state_name} state.sls ${FORMULA_NAME} || (log_err "Execution of ${FORMULA_NAME}.${state_name} failed"; exit 1)
+ done
+}
+
_atexit() {
RETVAL=$?
trap true INT TERM EXIT
@@ -155,6 +162,9 @@
run)
run
;;
+ real-run)
+ real_run
+ ;;
*)
prepare
run