#!/usr/bin/env python3 import pytest from starlette.testclient import TestClient from pyheatpump.variables import app, get_variables, set_variables, ROUTES def test_get_(set_test_db): c = TestClient(app) r = c.get('/') assert r.status_code == 200 d_resp = r.json() assert type(d_resp) is dict assert 'A' in d_resp.keys() print(d_resp) assert '10' in d_resp['A'].keys() assert len(d_resp['A'].keys()) == 4 assert len(d_resp['I'].keys()) == 4 assert len(d_resp['D'].keys()) == 4 @pytest.mark.skip def test_set_(set_test_db): c = TestClient(app) r = c.post('/') assert r.status_code == 200