MCPcopy
hub / github.com/photonixapp/photonix / test_all_libraries

Method test_all_libraries

tests/test_graphql.py:150–165  ·  view source on GitHub ↗

Test list of libraries.

(self)

Source from the content-addressed store, hash-verified

148 assert len(data['data']['allPhotos']['edges']) == 2
149
150 def test_all_libraries(self):
151 """Test list of libraries."""
152 query = """
153 {
154 allLibraries {
155 id
156 name
157 }
158 }
159 """
160 response = self.api_client.post_graphql(query)
161 data = get_graphql_content(response)
162 assert response.status_code == 200
163 assert len(data['data']['allLibraries']) == 1
164 self.assertEqual(data['data']['allLibraries'][0]['id'], str(self.defaults['library'].id), "Library id not matched.")
165 self.assertEqual(data['data']['allLibraries'][0]['name'], self.defaults['library'].name, "Library name not matched.")
166
167 def test_user_profile_data(self):
168 """Test profile data."""

Callers

nothing calls this directly

Calls 2

get_graphql_contentFunction · 0.85
post_graphqlMethod · 0.80

Tested by

no test coverage detected