
This commit takes the cookie cutter output and fixes it up into a snap that builds and installs. - Added required names and such in openstack-snap.yaml and nginx and wsgi config templates. - Python packages that are declared in setup.cfg and not in requirements.txt are now called out explicitly in the snapcraft.yaml. (Note: a better fix might be to update snapcraft to be able to parse dependencies from setup.cfg.) - Removed upper constraints files on Python packages (and removed oslo patch). Gnocchi does not appear to respect the upper constraints. - Added gnocchi-config-generator command to apps. - Used the above to generate a default config. - Added snapstack tests (though they don't work yet). There's still plenty to do: snapstack tests need to be fixed up (see the TODO in tests/gnocchi.sh), and the snap as a whole needs to be thoroughly tested.
29 lines
698 B
Python
29 lines
698 B
Python
import unittest
|
|
|
|
from snapstack import Plan, Setup, Step
|
|
|
|
class SnapstackTest(unittest.TestCase):
|
|
|
|
def test_snapstack(self):
|
|
'''
|
|
_test_snapstack_
|
|
|
|
Run a basic smoke test, utilizing our snapstack testing harness.
|
|
|
|
'''
|
|
gnocchi = Step(
|
|
snap='gnocchi',
|
|
script_loc='./tests/',
|
|
scripts=['gnocchi.sh'],
|
|
files=[
|
|
'etc/snap-gnocchi/gnocchi/gnocchi.conf'
|
|
],
|
|
snap_store=False)
|
|
|
|
gnocchi_cleanup = Step(
|
|
script_loc='./tests/',
|
|
scripts=['gnocchi_cleanup.sh'])
|
|
|
|
plan = Plan(tests=[gnocchi], test_cleanup=[gnocchi_cleanup])
|
|
plan.run()
|