source: buildhelpers/codegen/templates/__init__test.mustache@ 450bcad

debian/bullseye
Last change on this file since 450bcad was f9321aa, checked in by Joachim Langenbach <joachim.langenbach@…>, 7 years ago
  • Adapted code_generator to
    • handle several packages
    • to configure the port from yaml specification
    • to use the VERSION used by setup.py
  • Added deviceservice.yaml with first version of webservice
  • Moved Config loader and HttpErrors to gnuboat.common
  • Moved rrd archive schema to gnuboat.common.device
  • Property mode set to 100644
File size: 511 bytes
Line 
1from flask_testing import TestCase
2
3from {{packageName}}_impl.tests import (
4 create_app as orig_create_app,
5 setUp as orig_setUp,
6 tearDown as orig_tearDown
7)
8
9class BaseTestCase(TestCase):
10 def create_app(self):
11 return orig_create_app(self)
12
13 def setUp(self):
14 orig_setUp(self)
15
16 def tearDown(self):
17 orig_tearDown(self)
18
19 def check_key(self, key, value, data):
20 assert key in data, "{} not in data {}".format(key, data)
21 assert data[key] == value, "{} = {}".format(value, data[key])
Note: See TracBrowser for help on using the repository browser.