1
+ name : Run PGRX tests
2
+ on : [push, pull_request, workflow_dispatch]
3
+ permissions :
4
+ contents : read
5
+
6
+ jobs :
7
+ tester :
8
+ runs-on : ${{ matrix.platform.runs_on }}
9
+
10
+ strategy :
11
+ fail-fast : false
12
+ matrix :
13
+ pgvector :
14
+ - version : 0.7.4
15
+ pg :
16
+ - major : 15
17
+ minor : 7
18
+ - major : 16
19
+ minor : 3
20
+ platform :
21
+ - type : amd64
22
+ runs_on : ubuntu-latest
23
+ rustflags : ' -C target-feature=+avx2,+fma'
24
+ - type : arm64
25
+ runs_on : cloud-image-runner-arm64
26
+ rustflags : ' '
27
+
28
+ env :
29
+ PG_SRC_DIR : pgbuild
30
+ PG_INSTALL_DIR : postgresql
31
+ MAKE_JOBS : 6
32
+ PG_CONFIG_PATH : postgresql/bin/pg_config
33
+ TAG : ${{ github.event.inputs.tag }}
34
+ TAG_DIR : pgvectorscale
35
+ TAG_GIT_REF : ${{ github.event.inputs.TAG_GIT_REF == '' && github.event.inputs.tag || github.event.inputs.TAG_GIT_REF}}
36
+
37
+ steps :
38
+ - name : Checkout pgvectorscale
39
+ uses : actions/checkout@v4
40
+
41
+ - name : Install Linux Packages
42
+ uses : ./.github/actions/install-packages
43
+
44
+ - name : Install PostgreSQL ${{ matrix.pg.major }}
45
+ uses : ./.github/actions/install-postgres
46
+ with :
47
+ pg-version : ${{ matrix.pg.major }}.${{ matrix.pg.minor }}
48
+ pg-src-dir : ~/${{ env.PG_SRC_DIR }}
49
+ pg-install-dir : ~/${{ env.PG_INSTALL_DIR }}
50
+
51
+ - name : Install pgvector ${{ matrix.pgvector.version }}
52
+ uses : ./.github/actions/install-pgvector
53
+ with :
54
+ pgvector-version : ${{ matrix.pgvector.version }}
55
+ pg-install-dir : ~/${{ env.PG_INSTALL_DIR }}
56
+
57
+ - name : Install pgrx
58
+ uses : ./.github/actions/install-pgrx
59
+ with :
60
+ pg-install-dir : ~/${{ env.PG_INSTALL_DIR }}
61
+ pgrx-version : 0.11.1
62
+
63
+ - name : Run tests
64
+ id : runtests
65
+ run : |
66
+ cd pgvectorscale
67
+ ls
68
+ ${{ matrix.platform.rustflags != '' && format('RUSTFLAGS="{0}"', matrix.platform.rustflags) || '' }} cargo pgrx test -- pg${{ matrix.pg.major }}
0 commit comments