@@ -223,6 +223,7 @@ class AnalyzerTests: AppTestCase {
223223 $0. environment. loadSPIManifest = { _ in nil }
224224 $0. fileManager. fileExists = { @Sendable _ in true }
225225 $0. git. commitCount = { @Sendable _ in 12 }
226+ $0. git. firstCommitDate = { @Sendable _ in . t0 }
226227 $0. httpClient. mastodonPost = { @Sendable _ in }
227228 } operation: {
228229 // setup
@@ -247,7 +248,6 @@ class AnalyzerTests: AppTestCase {
247248 packageName: " foo-1 " ,
248249 reference: . tag( 1 , 0 , 0 ) ) . save ( on: app. db)
249250
250- Current . git. firstCommitDate = { @Sendable _ in . t0 }
251251 Current . git. lastCommitDate = { @Sendable _ in . t2 }
252252 Current . git. getTags = { @Sendable _ in [ . tag( 1 , 0 , 0 ) , . tag( 1 , 1 , 1 ) ] }
253253 Current . git. hasBranch = { @Sendable _, _ in true }
@@ -317,14 +317,14 @@ class AnalyzerTests: AppTestCase {
317317 $0. date. now = . now
318318 $0. fileManager. fileExists = { @Sendable _ in true }
319319 $0. git. commitCount = { @Sendable _ in 12 }
320+ $0. git. firstCommitDate = { @Sendable _ in . t0 }
320321 } operation: {
321322 // setup
322323 do {
323324 let pkg = try await savePackage ( on: app. db, " https://github.com/foo/1 " , processingStage: . ingestion)
324325 try await Repository ( package : pkg, defaultBranch: " main " ) . save ( on: app. db)
325326 }
326327
327- Current . git. firstCommitDate = { @Sendable _ in . t0 }
328328 Current . git. lastCommitDate = { @Sendable _ in . t1 }
329329 Current . git. hasBranch = { @Sendable _, _ in false } // simulate analysis error via branch mismatch
330330 Current . git. shortlog = { @Sendable _ in " " }
@@ -362,6 +362,7 @@ class AnalyzerTests: AppTestCase {
362362 $0. environment. loadSPIManifest = { _ in nil }
363363 $0. fileManager. fileExists = { @Sendable _ in true }
364364 $0. git. commitCount = { @Sendable _ in 12 }
365+ $0. git. firstCommitDate = { @Sendable _ in . t0 }
365366 } operation: {
366367 // setup
367368 let urls = [ " https://github.com/foo/1 " , " https://github.com/foo/2 " ]
@@ -371,7 +372,6 @@ class AnalyzerTests: AppTestCase {
371372 }
372373 let lastUpdate = Date ( )
373374
374- Current . git. firstCommitDate = { @Sendable _ in . t0 }
375375 Current . git. lastCommitDate = { @Sendable _ in . t1 }
376376 Current . git. getTags = { @Sendable _ in [ . tag( 1 , 0 , 0 ) ] }
377377 Current . git. hasBranch = { @Sendable _, _ in true }
@@ -524,9 +524,9 @@ class AnalyzerTests: AppTestCase {
524524 try await withDependencies {
525525 $0. fileManager. fileExists = { @Sendable _ in true }
526526 $0. git. commitCount = { @Sendable _ in 12 }
527+ $0. git. firstCommitDate = { @Sendable _ in . t0 }
527528 } operation: {
528529 // setup
529- Current . git. firstCommitDate = { @Sendable _ in . t0 }
530530 Current . git. lastCommitDate = { @Sendable _ in . t1 }
531531 Current . git. shortlog = { @Sendable _ in
532532 """
@@ -897,9 +897,9 @@ class AnalyzerTests: AppTestCase {
897897 $0. environment. loadSPIManifest = { _ in nil }
898898 $0. fileManager. fileExists = { @Sendable _ in true }
899899 $0. git. commitCount = { @Sendable _ in 12 }
900+ $0. git. firstCommitDate = { @Sendable _ in . t0 }
900901 } operation: {
901902 // setup
902- Current . git. firstCommitDate = { @Sendable _ in . t0 }
903903 Current . git. lastCommitDate = { @Sendable _ in . t1 }
904904 Current . git. getTags = { @Sendable _ in [ . tag( 1 , 0 , 0 ) , . tag( 2 , 0 , 0 ) ] }
905905 Current . git. hasBranch = { @Sendable _, _ in true }
@@ -1303,6 +1303,7 @@ class AnalyzerTests: AppTestCase {
13031303 try await withDependencies {
13041304 $0. fileManager. fileExists = { @Sendable _ in true }
13051305 $0. git. commitCount = { @Sendable _ in 2 }
1306+ $0. git. firstCommitDate = { @Sendable _ in . t0 }
13061307 } operation: {
13071308 let pkgId = UUID ( )
13081309 let pkg = Package ( id: pkgId, url: " 1 " . asGithubUrl. url, processingStage: . ingestion)
@@ -1323,7 +1324,6 @@ class AnalyzerTests: AppTestCase {
13231324 latest: . release,
13241325 packageName: " foo-1 " ,
13251326 reference: . tag( 1 , 0 , 0 ) ) . save ( on: app. db)
1326- Current . git. firstCommitDate = { @Sendable _ in . t0 }
13271327 Current . git. hasBranch = { @Sendable _, _ in true }
13281328 Current . git. lastCommitDate = { @Sendable _ in . t1 }
13291329 struct Error : Swift . Error { }
@@ -1409,6 +1409,7 @@ class AnalyzerTests: AppTestCase {
14091409 $0. date. now = . now
14101410 $0. fileManager. fileExists = { @Sendable _ in true }
14111411 $0. git. commitCount = { @Sendable _ in 2 }
1412+ $0. git. firstCommitDate = { @Sendable _ in . t0 }
14121413 } operation: {
14131414 let pkgId = UUID ( )
14141415 let pkg = Package ( id: pkgId, url: " 1 " . asGithubUrl. url, processingStage: . ingestion)
@@ -1429,7 +1430,6 @@ class AnalyzerTests: AppTestCase {
14291430 latest: . release,
14301431 packageName: " foo-1 " ,
14311432 reference: . tag( 1 , 0 , 0 ) ) . save ( on: app. db)
1432- Current . git. firstCommitDate = { @Sendable _ in . t0 }
14331433 Current . git. hasBranch = { @Sendable _, _ in true }
14341434 Current . git. lastCommitDate = { @Sendable _ in . t1 }
14351435 struct Error : Swift . Error { }
@@ -1520,6 +1520,7 @@ class AnalyzerTests: AppTestCase {
15201520 $0. environment. loadSPIManifest = { _ in nil }
15211521 $0. fileManager. fileExists = { @Sendable _ in true }
15221522 $0. git. commitCount = { @Sendable _ in 12 }
1523+ $0. git. firstCommitDate = { @Sendable _ in . t0 }
15231524 } operation: {
15241525 // setup
15251526 let pkg = try await savePackage ( on: app. db, id: . id0, " https://github.com/foo/1 " . url, processingStage: . ingestion)
@@ -1530,7 +1531,6 @@ class AnalyzerTests: AppTestCase {
15301531 stars: 100 ) . save ( on: app. db)
15311532 Current . git. getTags = { @Sendable _ in [ ] }
15321533 Current . git. hasBranch = { @Sendable _, _ in true }
1533- Current . git. firstCommitDate = { @Sendable _ in . t0 }
15341534 Current . git. lastCommitDate = { @Sendable _ in . t1 }
15351535 Current . git. revisionInfo = { @Sendable _, _ in . init( commit: " sha1 " , date: . t0) }
15361536 Current . git. shortlog = { @Sendable _ in " 10 \t Person 1 " }
0 commit comments