def test_valid_values(self): handler = make_htaccess( None, {}, 'Sample Realm', self.htaccess_path) assert isinstance(handler, HtaccessHandler)
def test_illegal_path(self): with pytest.raises(AssertionError): make_htaccess(None, {}, 'Sample Realm', 'not-existent-path')
def test_invalid_auth_type(self, htaccess_path): with pytest.raises(ValueError): make_htaccess( None, {}, 'Sample Realm', htaccess_path, 'invalid-auth')
def test_valid_values(self, htaccess_path): handler = make_htaccess( None, {}, 'Sample Realm', htaccess_path) assert isinstance(handler, HtaccessHandler)