Add kitchen tests
- add .kitchen.yml
- add .gitignore
Related PROD-27780 (PROD:27780)
Change-Id: I9b026d21f71d302783068e4275f83af7401bdc77
diff --git a/Makefile b/Makefile
index fb69046..5bc4dc4 100644
--- a/Makefile
+++ b/Makefile
@@ -38,6 +38,7 @@
@echo "make release-major - Generate new major release"
@echo "make release-minor - Generate new minor release"
@echo "make changelog - Show changes since last release"
+ @echo "make test-model-validate - Run salt jsonschema validation"
install:
# Formula
@@ -45,6 +46,7 @@
cp -a $(FORMULANAME) $(DESTDIR)/$(SALTENVDIR)/
[ ! -d _modules ] || cp -a _modules $(DESTDIR)/$(SALTENVDIR)/
[ ! -d _states ] || cp -a _states $(DESTDIR)/$(SALTENVDIR)/ || true
+ [ ! -d _engines ] || cp -a _engines $(DESTDIR)/$(SALTENVDIR)/ || true
[ ! -d _grains ] || cp -a _grains $(DESTDIR)/$(SALTENVDIR)/ || true
# Metadata
[ -d $(DESTDIR)/$(RECLASSDIR)/service/$(FORMULANAME) ] || mkdir -p $(DESTDIR)/$(RECLASSDIR)/service/$(FORMULANAME)
@@ -56,6 +58,10 @@
test:
[ ! -d tests ] || (cd tests; ./run_tests.sh)
+test-model-validate:
+ # TODO make it actually fail
+ [ ! -d $(FORMULANAME)/schemas/ ] || (cd tests; ./run_tests.sh model-validate)
+
release-major: check-changes
@echo "Current version is $(VERSION), new version is $(NEW_MAJOR_VERSION)"
@[ $(VERSION_MAJOR) != $(NEW_MAJOR_VERSION) ] || (echo "Major version $(NEW_MAJOR_VERSION) already released, nothing to do. Do you want release-minor?" && exit 1)