-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
113 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
#!/bin/bash | ||
|
||
set -Eexuo pipefail | ||
shopt -s nullglob | ||
|
||
srv="https://packages.edgedb.com" | ||
|
||
curl -fL "${srv}/dist/$(uname -m)-unknown-linux-musl/edgedb-cli" \ | ||
> "/usr/bin/edgedb" | ||
|
||
chmod +x "/usr/bin/edgedb" | ||
|
||
if command -v useradd >/dev/null 2>&1; then | ||
useradd --shell /bin/bash edgedb | ||
else | ||
# musllinux/alpine doesn't have useradd | ||
adduser -s /bin/bash -D edgedb | ||
fi | ||
|
||
su -l edgedb -c "edgedb server install --version ${EDGEDB_SERVER_VERSION}" | ||
ln -s $(su -l edgedb -c "edgedb server info --latest --bin-path") \ | ||
"/usr/bin/edgedb-server" | ||
|
||
edgedb-server --version |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
name: Tests | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
- ci | ||
pull_request: | ||
workflow_dispatch: | ||
inputs: {} | ||
|
||
jobs: | ||
test: | ||
runs-on: ${{ matrix.os }} | ||
|
||
defaults: | ||
run: | ||
shell: bash | ||
|
||
env: | ||
PIP_DISABLE_PIP_VERSION_CHECK: 1 | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
python-version: ["3.12"] | ||
edgedb-version: [nightly] | ||
os: [ubuntu-24.04] | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 50 | ||
submodules: true | ||
|
||
- name: "pg_config???" | ||
run: | | ||
pg_config || true | ||
- name: Install EdgeDB | ||
uses: edgedb/setup-edgedb@v1 | ||
with: | ||
server-version: ${{ matrix.edgedb-version }} | ||
|
||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Registering deb-src repositories | ||
run: | | ||
sudo sed -i 's/^Types: deb$/Types: deb deb-src/' /etc/apt/sources.list.d/ubuntu.sources | ||
sudo apt-get update | ||
- name: Install PostGIS build deps | ||
run: | | ||
sudo apt-get build-dep postgis | ||
- name: Install Postgres | ||
run: | | ||
sudo apt-get install postgresql-16 postgresql-server-dev-16 | ||
- name: Build extension package | ||
run: | | ||
PYTHON=$(dirname $(edgedb server info --latest --bin-path))/python3 | ||
make -j8 PYTHON=$PYTHON EDBFLAGS=--no-devmode PG_CONFIG=$(which pg_config) | ||
# - name: Install Python Deps | ||
# if: steps.release.outputs.version == 0 | ||
# run: | | ||
# python -m pip install --upgrade setuptools pip wheel | ||
# python -m pip install -e .[test] | ||
|
||
# - name: Test | ||
# if: steps.release.outputs.version == 0 | ||
# env: | ||
# LOOP_IMPL: ${{ matrix.loop }} | ||
# SERVER_VERSION: ${{ matrix.edgedb-version }} | ||
# run: | | ||
# if [ "${SERVER_VERSION}" = "nightly" ]; then | ||
# export EDGEDB_TEST_CODEGEN_ASSERT_SUFFIX=.assert | ||
# else | ||
# export EDGEDB_TEST_CODEGEN_ASSERT_SUFFIX=.assert${SERVER_VERSION} | ||
# fi | ||
# if [ "${LOOP_IMPL}" = "uvloop" ]; then | ||
# env USE_UVLOOP=1 python -m unittest -v tests.suite | ||
# else | ||
# python -m unittest -v tests.suite | ||
# fi |