Skip to content

Commit 936f619

Browse files
stephencelisgithub-actions[bot]
authored andcommitted
Run swift-format
1 parent 4e73309 commit 936f619

File tree

2 files changed

+39
-40
lines changed

2 files changed

+39
-40
lines changed

Sources/StructuredQueriesCore/AggregateFunctions.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,6 @@ extension QueryExpression where QueryValue: QueryBindable & _OptionalPromotable
100100
AggregateFunction("max", [queryFragment], filter: filter?.queryFragment)
101101
}
102102

103-
104103
/// A minimum aggregate of this expression.
105104
///
106105
/// ```swift

Tests/StructuredQueriesTests/AggregateFunctionsTests.swift

Lines changed: 39 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -94,45 +94,45 @@ extension SnapshotTests {
9494
}
9595
}
9696

97-
@Test func max() {
98-
assertInlineSnapshot(of: User.columns.birthDate.max(), as: .sql) {
99-
"""
100-
max("users"."birthDate")
101-
"""
102-
}
103-
assertQuery(Reminder.select { $0.dueDate.max() }) {
104-
"""
105-
SELECT max("reminders"."dueDate")
106-
FROM "reminders"
107-
"""
108-
}results: {
109-
"""
110-
┌────────────────────────────────┐
111-
│ Date(2001-01-05T00:00:00.000Z) │
112-
└────────────────────────────────┘
113-
"""
114-
}
115-
}
116-
117-
@Test func min() {
118-
assertInlineSnapshot(of: User.columns.birthDate.min(), as: .sql) {
119-
"""
120-
min("users"."birthDate")
121-
"""
122-
}
123-
assertQuery(Reminder.select { $0.dueDate.min() }) {
124-
"""
125-
SELECT min("reminders"."dueDate")
126-
FROM "reminders"
127-
"""
128-
} results: {
129-
"""
130-
┌────────────────────────────────┐
131-
│ Date(2000-06-25T00:00:00.000Z) │
132-
└────────────────────────────────┘
133-
"""
134-
}
135-
}
97+
@Test func max() {
98+
assertInlineSnapshot(of: User.columns.birthDate.max(), as: .sql) {
99+
"""
100+
max("users"."birthDate")
101+
"""
102+
}
103+
assertQuery(Reminder.select { $0.dueDate.max() }) {
104+
"""
105+
SELECT max("reminders"."dueDate")
106+
FROM "reminders"
107+
"""
108+
} results: {
109+
"""
110+
┌────────────────────────────────┐
111+
│ Date(2001-01-05T00:00:00.000Z) │
112+
└────────────────────────────────┘
113+
"""
114+
}
115+
}
116+
117+
@Test func min() {
118+
assertInlineSnapshot(of: User.columns.birthDate.min(), as: .sql) {
119+
"""
120+
min("users"."birthDate")
121+
"""
122+
}
123+
assertQuery(Reminder.select { $0.dueDate.min() }) {
124+
"""
125+
SELECT min("reminders"."dueDate")
126+
FROM "reminders"
127+
"""
128+
} results: {
129+
"""
130+
┌────────────────────────────────┐
131+
│ Date(2000-06-25T00:00:00.000Z) │
132+
└────────────────────────────────┘
133+
"""
134+
}
135+
}
136136

137137
@Test func sum() {
138138
assertInlineSnapshot(of: User.columns.id.sum(), as: .sql) {

0 commit comments

Comments
 (0)