Skip to content

Commit 2730cbb

Browse files
authored
Merge branch 'main' into jobs-retention
2 parents 5a36adb + 27247ee commit 2730cbb

File tree

4 files changed

+31
-13
lines changed

4 files changed

+31
-13
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,9 @@ jobs:
2020
strategy:
2121
matrix:
2222
image:
23-
- 'swift:5.9'
2423
- 'swift:5.10'
2524
- 'swift:6.0'
25+
- 'swift:6.1'
2626
postgres-image:
2727
- 'postgres:17'
2828
- 'postgres:16'

.github/workflows/nightly.yml

Lines changed: 25 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -10,17 +10,35 @@ jobs:
1010
strategy:
1111
matrix:
1212
image: ['nightly-focal', 'nightly-jammy', 'nightly-amazonlinux2']
13-
services:
14-
redis:
15-
image: redis
16-
ports:
17-
- 6379:6379
18-
options: --entrypoint redis-server
13+
postgres-image:
14+
- "postgres:17"
15+
- "postgres:14"
16+
include:
17+
- postgres-image: postgres:17
18+
postgres-auth: scram-sha-256
19+
- postgres-image: postgres:14
20+
postgres-auth: md5
1921

2022
container:
2123
image: swiftlang/swift:${{ matrix.image }}
24+
volumes: ["pgrunshare:/var/run/postgresql"]
2225
env:
23-
REDIS_HOSTNAME: "redis"
26+
POSTGRES_DB: "test_database"
27+
POSTGRES_USER: "test_user"
28+
POSTGRES_PASSWORD: "test_password"
29+
POSTGRES_HOSTNAME: "psql"
30+
POSTGRES_SOCKET: "/var/run/postgresql/.s.PGSQL.5432"
31+
POSTGRES_HOST_AUTH_METHOD: ${{ matrix.postgres-auth }}
32+
services:
33+
psql:
34+
image: ${{ matrix.postgres-image }}
35+
volumes: ["pgrunshare:/var/run/postgresql"]
36+
env:
37+
POSTGRES_DB: "test_database"
38+
POSTGRES_USER: "test_user"
39+
POSTGRES_PASSWORD: "test_password"
40+
POSTGRES_HOST_AUTH_METHOD: ${{ matrix.postgres-auth }}
41+
POSTGRES_INITDB_ARGS: --auth-host=${{ matrix.postgres-auth }}
2442

2543
steps:
2644
- name: Checkout

Package.swift

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// swift-tools-version: 5.9
1+
// swift-tools-version: 5.10
22

33
import PackageDescription
44

@@ -10,15 +10,15 @@ let package = Package(
1010
],
1111
dependencies: [
1212
// TODO: use a released version of swift-jobs
13-
.package(url: "https://github.com/hummingbird-project/swift-jobs.git", branch: "main"),
14-
.package(url: "https://github.com/hummingbird-project/hummingbird-postgres.git", from: "0.6.0"),
13+
.package(url: "https://github.com/hummingbird-project/swift-jobs.git", from: "1.0.0-beta.8"),
14+
.package(url: "https://github.com/hummingbird-project/postgres-migrations.git", from: "0.1.0"),
1515
.package(url: "https://github.com/vapor/postgres-nio.git", from: "1.25.0"),
1616
],
1717
targets: [
1818
.target(
1919
name: "JobsPostgres",
2020
dependencies: [
21-
.product(name: "PostgresMigrations", package: "hummingbird-postgres"),
21+
.product(name: "PostgresMigrations", package: "postgres-migrations"),
2222
.product(name: "Jobs", package: "swift-jobs"),
2323
.product(name: "PostgresNIO", package: "postgres-nio"),
2424
]

Tests/JobsPostgresTests/JobsTests.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -412,7 +412,7 @@ final class JobsTests: XCTestCase {
412412
struct TestParameters: JobParameters {
413413
static let jobName = "testErrorRetryCount"
414414
}
415-
let expectation = XCTestExpectation(description: "TestJob.execute was called", expectedFulfillmentCount: 4)
415+
let expectation = XCTestExpectation(description: "TestJob.execute was called", expectedFulfillmentCount: 3)
416416
struct FailedError: Error {}
417417
try await self.testJobQueue(numWorkers: 1) { jobQueue in
418418
jobQueue.registerJob(

0 commit comments

Comments
 (0)