diff --git a/.github/lambdaminer/data/test_data/location.sql b/.github/lambdaminer/data/test_data/location.sql new file mode 100644 index 0000000..77f7469 --- /dev/null +++ b/.github/lambdaminer/data/test_data/location.sql @@ -0,0 +1,18 @@ +-- SPDX-FileCopyrightText: 2024 Helmholtz Centre for Environmental Research GmbH - UFZ +-- +-- SPDX-License-Identifier: LicenseRef-UFZ-GPL-3.0-or-later + +-- +-- Data for Name: location; Type: TABLE DATA; Schema: public; Owner: lmdb_adm +-- + +INSERT INTO public.location (location_id, height, latitude, longitude, country, state, zipcode, site_description) VALUES (1, 12.000000, 51.340199, 12.360103, 'Germany', 'Sachsen', '04318', 'Leipzig'); +INSERT INTO public.location (location_id, height, latitude, longitude, country, state, zipcode, site_description) VALUES (2, NULL, 51.867139, 10.870583, 'Germany', 'Sachsen-Anhalt', '38855', 'Holtemme, downstream of WWTP Silstedt'); +INSERT INTO public.location (location_id, height, latitude, longitude, country, state, zipcode, site_description) VALUES (3, NULL, 29.288333, -83.165833, 'USA', 'Florida', '4131', 'Dummy Site Description for SRFA'); +INSERT INTO public.location (location_id, height, latitude, longitude, country, state, zipcode, site_description) VALUES (5, NULL, 29.288333, -83.165833, 'USA', 'Florida', '4131', 'Test Site Description'); + +-- +-- Name: location_location_id_seq; Type: SEQUENCE SET; Schema: public; Owner: lmdb_adm +-- + +SELECT pg_catalog.setval('public.location_location_id_seq', 5, true); diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 57f5e55..719c85c 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -162,9 +162,13 @@ jobs: # Set up the lambda-miner database - name: Create a database in the postgres for lambda-miner run: | - PGPASSWORD=postgres psql -h localhost -U postgres -c "CREATE DATABASE lambda_miner;" - PGPASSWORD=postgres psql -h localhost -U postgres -d lambda_miner -q -f ./.github/lambdaminer/build.sql - PGPASSWORD=postgres psql -h localhost -U postgres -d lambda_miner -c "SELECT * FROM public.instrument;" + PGPASSWORD=postgres psql -h localhost -U postgres -c "CREATE DATABASE lmdb;" + + - name: Build the lambda-miner and run a test + run: | + PGPASSWORD=postgres psql -h localhost -U postgres -d lmdb -q -f ./.github/lambdaminer/build.sql + sleep 10 + PGPASSWORD=postgres psql -h localhost -U postgres -d lmdb -c "SELECT * FROM public.instrument;" # Start OMERO - name: Start OMERO diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml index 0c03f13..3b67902 100644 --- a/.github/workflows/pr.yaml +++ b/.github/workflows/pr.yaml @@ -305,12 +305,16 @@ jobs: singularity pull --dir /tmp docker://rocker/tidyverse fi - # Set up the lambda-miner database + # Set up the lambda-miner database - name: Create a database in the postgres for lambda-miner run: | - PGPASSWORD=postgres psql -h localhost -U postgres -c "CREATE DATABASE lambda_miner;" - PGPASSWORD=postgres psql -h localhost -U postgres -d lambda_miner -q -f ./.github/lambdaminer/build.sql - PGPASSWORD=postgres psql -h localhost -U postgres -d lambda_miner -c "SELECT * FROM public.instrument;" + PGPASSWORD=postgres psql -h localhost -U postgres -c "CREATE DATABASE lmdb;" + + - name: Build the lambda-miner and run a test + run: | + PGPASSWORD=postgres psql -h localhost -U postgres -d lmdb -q -f ./.github/lambdaminer/build.sql + sleep 10 + PGPASSWORD=postgres psql -h localhost -U postgres -d lmdb -c "SELECT * FROM public.instrument;" # Start OMERO - name: Start OMERO