Skip to content

Commit

Permalink
Revert DB on the error path in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
fpseverino committed Dec 9, 2024
1 parent 2892c58 commit d3bc7c8
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Tests/AppTests/AppTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ struct AppTests {
let app = try await Application.make(.testing)
do {
try await configure(app)
{{#fluent}}try await app.autoRevert()
try await app.autoMigrate()
{{#fluent}}try await app.autoMigrate()
{{/fluent}} try await test(app)
{{#fluent}}try await app.autoRevert()
{{/fluent}} }
catch {
try await app.asyncShutdown()
{{#fluent}}try? await app.autoRevert()
{{/fluent}} try await app.asyncShutdown()
throw error
}
try await app.asyncShutdown()
Expand Down

0 comments on commit d3bc7c8

Please sign in to comment.