тестировать пользователь регистра API

    def test_api_register_user(self):
        response = self.client.post('/api/users', json={
            'username': 'bob',
            'email': 'bob@example.com',
            'password': 'bar'
        })
        assert response.status_code == 201

        # make sure the user is in the database
        user = User.query.filter_by(username='bob').first()
        assert user is not None
        assert user.email == 'bob@example.com'
Puzzled Puffin