Skip to content

Commit

Permalink
fixing tests
Browse files Browse the repository at this point in the history
  • Loading branch information
John Waller committed Oct 28, 2024
1 parent 680f0ff commit ce5d1c3
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 11 deletions.
5 changes: 2 additions & 3 deletions test/test-registry-networks.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,10 @@ def test_networks():
res = registry.networks()
assert dict == res.__class__
assert 2 == len(res)
assert 13 == len(res["data"])
assert 14 == len(res["data"])
assert ["data", "meta"] == sorted(res.keys())


@vcr.use_cassette("test/vcr_cassettes/test_networks_limit.yaml")
5@vcr.use_cassette("test/vcr_cassettes/test_networks_limit.yaml")
def test_networks_limit():
"registry.networks - limit param "
res = registry.networks(limit=5)
Expand Down
16 changes: 8 additions & 8 deletions test/vcr_cassettes/test_networks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ interactions:
uri: https://api.gbif.org/v1/network?limit=100
response:
body:
string: "{\"offset\":0,\"limit\":100,\"endOfRecords\":true,\"count\":13,\"results\":[{\"key\":\"a6cdb5d1-d358-4ac0-b75c-2c33cf6c8936\",\"title\":\"Long-term
string: "{\"offset\":0,\"limit\":100,\"endOfRecords\":true,\"count\":14,\"results\":[{\"key\":\"de82b0c2-ced8-4dde-8e87-fc54edd756ec\",\"title\":\"VectorNet\",\"language\":\"eng\",\"numConstituents\":1,\"email\":[],\"phone\":[],\"homepage\":[],\"address\":[],\"createdBy\":\"andrea\",\"modifiedBy\":\"andrea\",\"created\":\"2024-10-14T09:05:59.134+00:00\",\"modified\":\"2024-10-14T09:05:59.134+00:00\",\"contacts\":[],\"endpoints\":[],\"machineTags\":[],\"tags\":[],\"identifiers\":[],\"comments\":[]},{\"key\":\"a6cdb5d1-d358-4ac0-b75c-2c33cf6c8936\",\"title\":\"Long-term
Ecological Research Program - PELD/CNPq, Brazil\",\"description\":\"The PELD
program, held for 23 years by the National Council for Scientific and Technological
Development (CNPq) is maintained by ongoing Public Calls. The PELD network
Expand All @@ -29,7 +29,7 @@ interactions:
research that can address environmental issues and point to solutions and
practices for sustainable use of natural resources and ecosystem services,
with important contributions to the proposition of public policies, promoting
biodiversity conservation and human welfare.\\n\\nhttps://www.gov.br/cnpq/pt-br/acesso-a-informacao/acoes-e-programas/programas/peld\",\"language\":\"eng\",\"numConstituents\":44,\"email\":[],\"phone\":[],\"homepage\":[],\"address\":[],\"createdBy\":\"andrea\",\"modifiedBy\":\"andrea\",\"created\":\"2024-03-11T14:48:10.451+00:00\",\"modified\":\"2024-03-11T14:54:56.037+00:00\",\"contacts\":[{\"key\":5179449,\"type\":\"ADMINISTRATIVE_POINT_OF_CONTACT\",\"primary\":false,\"userId\":[],\"firstName\":\"Conselho
biodiversity conservation and human welfare.\\n\\nhttps://www.gov.br/cnpq/pt-br/acesso-a-informacao/acoes-e-programas/programas/peld\",\"language\":\"eng\",\"numConstituents\":48,\"email\":[],\"phone\":[],\"homepage\":[],\"address\":[],\"createdBy\":\"andrea\",\"modifiedBy\":\"andrea\",\"created\":\"2024-03-11T14:48:10.451+00:00\",\"modified\":\"2024-03-11T14:54:56.037+00:00\",\"contacts\":[{\"key\":5179449,\"type\":\"ADMINISTRATIVE_POINT_OF_CONTACT\",\"primary\":false,\"userId\":[],\"firstName\":\"Conselho
Nacional de Desenvolvimento Cient\xEDfico e Tecnol\xF3gico (CNPq/MCTI)\",\"position\":[],\"email\":[\"peld@cnpq.br\"],\"phone\":[],\"homepage\":[],\"address\":[],\"createdBy\":\"andrea\",\"modifiedBy\":\"andrea\",\"created\":\"2024-03-11T14:48:56.732+00:00\",\"modified\":\"2024-03-11T14:53:54.442+00:00\"},{\"key\":5179450,\"type\":\"ADMINISTRATIVE_POINT_OF_CONTACT\",\"primary\":false,\"userId\":[],\"firstName\":\"Sistema
de Informa\xE7\xE3o sobre a biodiversidade Brasileira (SiBBr)\",\"position\":[],\"email\":[\"atendimento_sibbr@rnp.br\"],\"phone\":[],\"homepage\":[],\"address\":[],\"createdBy\":\"andrea\",\"modifiedBy\":\"andrea\",\"created\":\"2024-03-11T14:49:36.777+00:00\",\"modified\":\"2024-03-11T14:54:04.531+00:00\"}],\"endpoints\":[],\"machineTags\":[],\"tags\":[],\"identifiers\":[],\"comments\":[]},{\"key\":\"0b00b924-016b-4954-96a7-2d9264b5d0ba\",\"title\":\"SwissBIF
(swissbif.ch) : Swiss Biodiversity Information Facility [Daten Biodiversit\xE4t
Expand All @@ -46,7 +46,7 @@ interactions:
contributions, cantonal agencies for conservation, administrations of protected
areas, federal offices. Participants to the network work under common procedures,
an agreed ethical framework and coordinated data flow that ease providing
access to multidimensional and coherent data.\",\"language\":\"eng\",\"numConstituents\":12,\"email\":[],\"phone\":[],\"homepage\":[],\"address\":[],\"createdBy\":\"andrea\",\"modifiedBy\":\"andrea\",\"created\":\"2024-03-01T14:17:44.135+00:00\",\"modified\":\"2024-03-01T14:17:44.135+00:00\",\"contacts\":[],\"endpoints\":[],\"machineTags\":[],\"tags\":[],\"identifiers\":[],\"comments\":[]},{\"key\":\"2ee1bff7-0b34-4fa3-9433-feaa7c6ee08b\",\"title\":\"Biodiversidad
access to multidimensional and coherent data.\",\"language\":\"eng\",\"numConstituents\":13,\"email\":[],\"phone\":[],\"homepage\":[],\"address\":[],\"createdBy\":\"andrea\",\"modifiedBy\":\"andrea\",\"created\":\"2024-03-01T14:17:44.135+00:00\",\"modified\":\"2024-03-01T14:17:44.135+00:00\",\"contacts\":[],\"endpoints\":[],\"machineTags\":[],\"tags\":[],\"identifiers\":[],\"comments\":[]},{\"key\":\"2ee1bff7-0b34-4fa3-9433-feaa7c6ee08b\",\"title\":\"Biodiversidad
y Desarrollo Colombia\",\"description\":\"Biodiversidad y Desarrollo es una
plataforma para promover y amplificar la gesti\xF3n empresarial en biodiversidad.
Inicia en el a\xF1o 2014 en la Asociaci\xF3n Nacional de Empresarios de Colombia
Expand Down Expand Up @@ -87,11 +87,11 @@ interactions:
2018 to develop a comprehensive Construction Masterplan, which will be followed
by a construction phase. The RI will become fully operational in 2025. More
information is available at the https://dissco.eu. Information about the technical
architecture can be found at: https://blog.dissco.tech.\",\"language\":\"eng\",\"numConstituents\":627,\"email\":[],\"phone\":[],\"homepage\":[\"https://www.dissco.eu\"],\"address\":[],\"createdBy\":\"mgrosjean\",\"modifiedBy\":\"wouter.addink\",\"created\":\"2021-04-09T13:02:15.137+00:00\",\"modified\":\"2021-04-09T15:35:54.762+00:00\",\"contacts\":[{\"key\":2371590,\"type\":\"TECHNICAL_POINT_OF_CONTACT\",\"primary\":true,\"userId\":[],\"firstName\":\"Wouter\",\"lastName\":\"Addink\",\"position\":[\"GBIF
architecture can be found at: https://blog.dissco.tech.\",\"language\":\"eng\",\"numConstituents\":628,\"email\":[],\"phone\":[],\"homepage\":[\"https://www.dissco.eu\"],\"address\":[],\"createdBy\":\"mgrosjean\",\"modifiedBy\":\"wouter.addink\",\"created\":\"2021-04-09T13:02:15.137+00:00\",\"modified\":\"2021-04-09T15:35:54.762+00:00\",\"contacts\":[{\"key\":2371590,\"type\":\"TECHNICAL_POINT_OF_CONTACT\",\"primary\":true,\"userId\":[],\"firstName\":\"Wouter\",\"lastName\":\"Addink\",\"position\":[\"GBIF
node manager for DiSSCo\",\"Coordinator Research-data and E-infrastructure\"],\"email\":[\"info@dissco.eu\"],\"phone\":[],\"homepage\":[\"dissco.eu\"],\"organization\":\"Naturalis
Biodiversity Center\",\"address\":[],\"city\":\"Leiden\",\"country\":\"NL\",\"postalCode\":\"2300
RA\",\"createdBy\":\"mgrosjean\",\"modifiedBy\":\"wouter.addink\",\"created\":\"2021-04-09T13:04:41.842+00:00\",\"modified\":\"2021-04-09T15:41:50.300+00:00\"}],\"endpoints\":[],\"machineTags\":[],\"tags\":[],\"identifiers\":[],\"comments\":[]},{\"key\":\"3aee7756-565e-4dc5-b22c-f997fbd7105c\",\"title\":\"Virtuelles
Herbarium Deutschland / Virtual Herbarium Germany\",\"language\":\"eng\",\"numConstituents\":24,\"email\":[],\"phone\":[],\"homepage\":[],\"address\":[],\"createdBy\":\"Andrea\",\"modifiedBy\":\"Andrea\",\"created\":\"2021-02-01T09:45:30.307+00:00\",\"modified\":\"2021-02-01T09:45:30.307+00:00\",\"contacts\":[{\"key\":2301987,\"type\":\"ADMINISTRATIVE_POINT_OF_CONTACT\",\"primary\":false,\"userId\":[],\"firstName\":\"J\xF6rg\",\"lastName\":\"Holetschek\",\"position\":[],\"email\":[\"J.Holetschek@bgbm.org\"],\"phone\":[],\"homepage\":[],\"address\":[],\"city\":\"Berlin\",\"country\":\"DE\",\"createdBy\":\"Andrea\",\"modifiedBy\":\"Andrea\",\"created\":\"2021-02-01T10:36:10.175+00:00\",\"modified\":\"2021-02-01T10:36:10.175+00:00\"},{\"key\":2301988,\"type\":\"ADMINISTRATIVE_POINT_OF_CONTACT\",\"primary\":false,\"userId\":[],\"firstName\":\"Wolf-Henning\",\"lastName\":\"Kusber\",\"position\":[],\"email\":[\"w.h.kusber@bgbm.org\"],\"phone\":[],\"homepage\":[],\"address\":[],\"city\":\"Berlin\",\"country\":\"DE\",\"createdBy\":\"Andrea\",\"modifiedBy\":\"Andrea\",\"created\":\"2021-02-01T10:37:11.523+00:00\",\"modified\":\"2021-02-01T10:37:11.523+00:00\"}],\"endpoints\":[],\"machineTags\":[],\"tags\":[],\"identifiers\":[],\"comments\":[]},{\"key\":\"99d66b6c-9087-452f-a9d4-f15f2c2d0e7e\",\"title\":\"VertNet\",\"language\":\"eng\",\"numConstituents\":637,\"email\":[],\"phone\":[],\"homepage\":[],\"address\":[],\"createdBy\":\"Andrea\",\"modifiedBy\":\"trobertson\",\"created\":\"2021-01-08T13:40:19.570+00:00\",\"modified\":\"2022-05-27T18:09:55.434+00:00\",\"contacts\":[],\"endpoints\":[],\"machineTags\":[],\"tags\":[],\"identifiers\":[],\"comments\":[]},{\"key\":\"379a0de5-f377-4661-9a30-33dd844e7b9a\",\"title\":\"Living
Herbarium Deutschland / Virtual Herbarium Germany\",\"language\":\"eng\",\"numConstituents\":24,\"email\":[],\"phone\":[],\"homepage\":[],\"address\":[],\"createdBy\":\"Andrea\",\"modifiedBy\":\"Andrea\",\"created\":\"2021-02-01T09:45:30.307+00:00\",\"modified\":\"2021-02-01T09:45:30.307+00:00\",\"contacts\":[{\"key\":2301987,\"type\":\"ADMINISTRATIVE_POINT_OF_CONTACT\",\"primary\":false,\"userId\":[],\"firstName\":\"J\xF6rg\",\"lastName\":\"Holetschek\",\"position\":[],\"email\":[\"J.Holetschek@bgbm.org\"],\"phone\":[],\"homepage\":[],\"address\":[],\"city\":\"Berlin\",\"country\":\"DE\",\"createdBy\":\"Andrea\",\"modifiedBy\":\"Andrea\",\"created\":\"2021-02-01T10:36:10.175+00:00\",\"modified\":\"2021-02-01T10:36:10.175+00:00\"},{\"key\":2301988,\"type\":\"ADMINISTRATIVE_POINT_OF_CONTACT\",\"primary\":false,\"userId\":[],\"firstName\":\"Wolf-Henning\",\"lastName\":\"Kusber\",\"position\":[],\"email\":[\"w.h.kusber@bgbm.org\"],\"phone\":[],\"homepage\":[],\"address\":[],\"city\":\"Berlin\",\"country\":\"DE\",\"createdBy\":\"Andrea\",\"modifiedBy\":\"Andrea\",\"created\":\"2021-02-01T10:37:11.523+00:00\",\"modified\":\"2021-02-01T10:37:11.523+00:00\"}],\"endpoints\":[],\"machineTags\":[],\"tags\":[],\"identifiers\":[],\"comments\":[]},{\"key\":\"99d66b6c-9087-452f-a9d4-f15f2c2d0e7e\",\"title\":\"VertNet\",\"language\":\"eng\",\"numConstituents\":636,\"email\":[],\"phone\":[],\"homepage\":[],\"address\":[],\"createdBy\":\"Andrea\",\"modifiedBy\":\"trobertson\",\"created\":\"2021-01-08T13:40:19.570+00:00\",\"modified\":\"2022-05-27T18:09:55.434+00:00\",\"contacts\":[],\"endpoints\":[],\"machineTags\":[],\"tags\":[],\"identifiers\":[],\"comments\":[]},{\"key\":\"379a0de5-f377-4661-9a30-33dd844e7b9a\",\"title\":\"Living
Norway Ecological Data Network\",\"language\":\"eng\",\"numConstituents\":122,\"email\":[],\"phone\":[],\"homepage\":[],\"address\":[],\"createdBy\":\"Andrea\",\"modifiedBy\":\"Andrea\",\"created\":\"2020-11-10T09:03:56.148+00:00\",\"modified\":\"2020-11-10T09:03:56.148+00:00\",\"contacts\":[],\"endpoints\":[],\"machineTags\":[{\"key\":7598721,\"namespace\":\"registry.gbif.org\",\"name\":\"visibleOnDatasetPage\",\"value\":\"true\",\"createdBy\":\"trobertson\",\"created\":\"2021-01-20T15:43:23.755+00:00\"}],\"tags\":[],\"identifiers\":[],\"comments\":[]},{\"key\":\"b153643d-735a-440f-a0e9-428b4f9d1cd2\",\"title\":\"TrIAS\",\"description\":\"TrIAS
is Belgian project building an open data-driven framework to support policy
on invasive species.\",\"language\":\"eng\",\"numConstituents\":39,\"email\":[],\"phone\":[],\"homepage\":[],\"address\":[],\"createdBy\":\"Andrea\",\"modifiedBy\":\"Andrea\",\"created\":\"2019-06-17T10:59:35.820+00:00\",\"modified\":\"2019-06-17T10:59:35.820+00:00\",\"contacts\":[],\"endpoints\":[],\"machineTags\":[{\"key\":7655748,\"namespace\":\"registry.gbif.org\",\"name\":\"visibleOnDatasetPage\",\"value\":\"true\",\"createdBy\":\"trobertson\",\"created\":\"2021-01-26T15:55:48.505+00:00\"}],\"tags\":[],\"identifiers\":[],\"comments\":[]},{\"key\":\"1f2c0cbe-40df-43f6-ba07-e76133e78c31\",\"title\":\"Arctos\",\"description\":\"Arctos
Expand All @@ -112,7 +112,7 @@ interactions:
Life and Freshwater BON\",\"language\":\"eng\",\"numConstituents\":59,\"email\":[],\"phone\":[],\"homepage\":[\"http://www.freshwaterplatform.eu\"],\"address\":[],\"createdBy\":\"mgrosjean\",\"modifiedBy\":\"mgrosjean\",\"created\":\"2019-02-28T10:57:05.677+00:00\",\"modified\":\"2019-02-28T10:57:05.677+00:00\",\"contacts\":[],\"endpoints\":[],\"machineTags\":[{\"key\":7655747,\"namespace\":\"registry.gbif.org\",\"name\":\"visibleOnDatasetPage\",\"value\":\"true\",\"createdBy\":\"trobertson\",\"created\":\"2021-01-26T15:55:08.507+00:00\"}],\"tags\":[],\"identifiers\":[],\"comments\":[]},{\"key\":\"2b7c7b4f-4d4f-40d3-94de-c28b6fa054a6\",\"title\":\"Ocean
Biodiversity Information System (OBIS)\",\"description\":\"The Ocean Biodiversity
Information System (OBIS) is a global open-access data and information clearing-house
on marine biodiversity for science, conservation and sustainable development.\",\"language\":\"eng\",\"numConstituents\":2763,\"email\":[],\"phone\":[],\"homepage\":[\"https://obis.org\"],\"logoUrl\":\"https://obis.org/images/logo.png\",\"address\":[],\"createdBy\":\"ADMIN\",\"modifiedBy\":\"MattBlissett\",\"created\":\"2007-04-03T08:31:37.000+00:00\",\"modified\":\"2020-06-17T11:34:47.474+00:00\",\"contacts\":[],\"endpoints\":[],\"machineTags\":[{\"key\":7598741,\"namespace\":\"registry.gbif.org\",\"name\":\"visibleOnDatasetPage\",\"value\":\"true\",\"createdBy\":\"MattBlissett\",\"created\":\"2021-01-20T15:54:18.923+00:00\"}],\"tags\":[],\"identifiers\":[],\"comments\":[]}]}"
on marine biodiversity for science, conservation and sustainable development.\",\"language\":\"eng\",\"numConstituents\":2767,\"email\":[],\"phone\":[],\"homepage\":[\"https://obis.org\"],\"logoUrl\":\"https://obis.org/images/logo.png\",\"address\":[],\"createdBy\":\"ADMIN\",\"modifiedBy\":\"MattBlissett\",\"created\":\"2007-04-03T08:31:37.000+00:00\",\"modified\":\"2020-06-17T11:34:47.474+00:00\",\"contacts\":[],\"endpoints\":[],\"machineTags\":[{\"key\":7598741,\"namespace\":\"registry.gbif.org\",\"name\":\"visibleOnDatasetPage\",\"value\":\"true\",\"createdBy\":\"MattBlissett\",\"created\":\"2021-01-20T15:54:18.923+00:00\"}],\"tags\":[],\"identifiers\":[],\"comments\":[]}]}"
headers:
Accept-Ranges:
- bytes
Expand All @@ -125,7 +125,7 @@ interactions:
Content-Type:
- application/json
Date:
- Fri, 04 Oct 2024 07:00:28 GMT
- Mon, 28 Oct 2024 15:58:42 GMT
Expires:
- '0'
Pragma:
Expand All @@ -141,7 +141,7 @@ interactions:
X-Frame-Options:
- DENY
X-Varnish:
- '657589179'
- '548373762'
X-XSS-Protection:
- 1; mode=block
status:
Expand Down

0 comments on commit ce5d1c3

Please sign in to comment.