| Total Complexity | 3 |
| Total Lines | 30 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | import os |
||
| 2 | import pytest |
||
| 3 | |||
| 4 | from unittest import TestCase |
||
| 5 | from run import create_app |
||
| 6 | |||
| 7 | |||
| 8 | class TestTestingConfig(TestCase): |
||
| 9 | app = create_app("testing") |
||
| 10 | |||
| 11 | def test_app_is_testing(self): |
||
| 12 | self.assertTrue(self.app.config['DEBUG'] is True) |
||
| 13 | self.assertTrue(self.app.config['TESTING'] is True) |
||
| 14 | |||
| 15 | |||
| 16 | class TestDevelopmentConfig(TestCase): |
||
| 17 | app = create_app("development") |
||
| 18 | |||
| 19 | def test_app_is_development(self): |
||
| 20 | self.assertTrue(self.app.config['DEBUG'] is True) |
||
| 21 | |||
| 22 | |||
| 23 | |||
| 24 | class TestProductionConfig(TestCase): |
||
| 25 | app = create_app("production") |
||
| 26 | |||
| 27 | def test_app_is_production(self): |
||
| 28 | self.assertTrue(self.app.config['DEBUG'] is False) |
||
| 29 | self.assertTrue(self.app.config['TESTING'] is False) |