-
Notifications
You must be signed in to change notification settings - Fork 96
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Replace Travis with GitHub Workflows
Travis has not worked in a while, so switch to GitHub workflows. All previous tests aside from Postgres upgrades have been replicated (and upgrades should be back soon). In the process, discover missing update SQL, so add it to `sql/pgtap--1.1.0--1.2.0.sql`. Yay testing! Also add a workflow for releasing pgTAP with a semantic version tag.
- Loading branch information
Showing
13 changed files
with
331 additions
and
418 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 |
---|---|---|
@@ -1,5 +1,5 @@ | ||
.gitignore export-ignore | ||
.gitattributes export-ignore | ||
tocgen export-ignore | ||
.travis.yml export-ignore | ||
.release.mmd export-ignore | ||
.github export-ignore |
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,37 @@ | ||
name: 🚀 Release | ||
on: | ||
push: | ||
tags: [v*] | ||
jobs: | ||
release: | ||
name: 🚀 Release on GitHub and PGXN | ||
runs-on: ubuntu-latest | ||
container: pgxn/pgxn-tools | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
PGXN_USERNAME: ${{ secrets.PGXN_USERNAME }} | ||
PGXN_PASSWORD: ${{ secrets.PGXN_PASSWORD }} | ||
steps: | ||
- name: Check out the repo | ||
uses: actions/checkout@v2 | ||
- name: Bundle the Release | ||
id: bundle | ||
run: pgxn-bundle | ||
- name: Release on PGXN | ||
run: pgxn-release | ||
- name: Generate Release Changes | ||
run: make latest-changes.md | ||
- name: Create GitHub Release | ||
id: release | ||
uses: actions/create-release@v1 | ||
with: | ||
tag_name: ${{ github.ref }} | ||
release_name: Release ${{ github.ref }} | ||
body_path: latest-changes.md | ||
- name: Upload Release Asset | ||
uses: actions/upload-release-asset@v1 | ||
with: | ||
upload_url: ${{ steps.release.outputs.upload_url }} | ||
asset_path: ./${{ steps.bundle.outputs.bundle }} | ||
asset_name: ${{ steps.bundle.outputs.bundle }} | ||
asset_content_type: application/zip |
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,63 @@ | ||
name: 🐘 Test | ||
on: | ||
push: | ||
pull_request: | ||
schedule: | ||
- cron: '0 14 3 * *' # Monthly at 2pm on the third | ||
jobs: | ||
build: | ||
strategy: | ||
matrix: | ||
include: | ||
- { version: 14, upgrade_to: "", update_from: 0.99.0 } | ||
- { version: 13, upgrade_to: 14, update_from: 0.99.0 } | ||
- { version: 12, upgrade_to: 13, update_from: 0.99.0 } | ||
- { version: 11, upgrade_to: 12, update_from: 0.99.0 } # Versions prior to 0.99.0 don't support Postgres 11 | ||
- { version: 10, upgrade_to: 11, update_from: 0.95.0 } | ||
- { version: 9.6, upgrade_to: 10, update_from: 0.95.0 } | ||
- { version: 9.5, upgrade_to: 9.6, update_from: 0.95.0 } | ||
- { version: 9.4, upgrade_to: 9.5, update_from: 0.95.0 } | ||
- { version: 9.3, upgrade_to: 9.4, update_from: 0.95.0 } | ||
- { version: 9.2, upgrade_to: 9.3, update_from: "" } # updatecheck is not supported prior to 9.3 | ||
- { version: 9.1, upgrade_to: 9.2, update_from: "" } | ||
# Also test pg_upgrade across many versions | ||
# - { version: 9.1, upgrade_to: 14, update_from: 0.99.0 } | ||
# - { version: 9.4, upgrade_to: 14, update_from: 0.99.0 } | ||
name: 🐘 PostgreSQL ${{ matrix.version }} | ||
runs-on: ubuntu-latest | ||
container: pgxn/pgxn-tools | ||
env: | ||
PGUSER: postgres | ||
UPDATE_FROM: "${{ matrix.update_from }}" | ||
steps: | ||
- run: pg-start ${{ matrix.version }} | ||
- uses: actions/checkout@v2 | ||
|
||
# Basic regression test. | ||
- run: pg-build-test | ||
|
||
# Test update. | ||
- run: 'if [ -d "$UPDATE_FROM" ]; then make uninstall clean updatecheck; fi' | ||
|
||
# Test upgrade. | ||
# - run: ./test/test_MVU.sh -s 55667 55778 "{{ matrix.version }}" "{{ matrix.upgrade_to }}" "/usr/lib/postgresql/{{ matrix.version }}/bin/" "/usr/lib/postgresql/{{ matrix.upgrade_to }}/bin/" | ||
|
||
# Test all, install, test, test-serial, and test-parallel, both from clean | ||
# repo and repeated with existing build, with and without PARALLEL_CONN=1. | ||
- run: make uninstall clean all | ||
- run: make all | ||
- run: make uninstall clean install | ||
- run: make install | ||
- run: "psql -Ec 'CREATE EXTENSION pgtap'" | ||
- run: make uninstall clean test | ||
- run: make test | ||
- run: make uninstall clean test PARALLEL_CONN=1 | ||
- run: make test PARALLEL_CONN=1 | ||
- run: make uninstall clean test-serial | ||
- run: make test-serial | ||
- run: make uninstall clean test-serial PARALLEL_CONN=1 | ||
- run: make test-serial PARALLEL_CONN=1 | ||
- run: make uninstall clean test-parallel | ||
- run: make test-parallel | ||
- run: make uninstall clean test-parallel PARALLEL_CONN=1 | ||
- run: make test-parallel PARALLEL_CONN=1 |
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 |
---|---|---|
|
@@ -27,6 +27,7 @@ bbin | |
*.sql.orig | ||
|
||
test/build | ||
/latest-changes.md | ||
|
||
# Misc mac crap | ||
.DS_Store |
This file was deleted.
Oops, something went wrong.
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
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
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
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
Oops, something went wrong.