     let migrationNeededFromV3toV1 = try CoreDataPlus.isMigrationNecessary(for: sourceURLV2, to: SampleModelVersion.version1)
     XCTAssertFalse(migrationNeededFromV3toV1)
   }
-  
+
   func testMigrationFromVersion1ToVersion2() throws {
     let bundle = Bundle(for: CoreDataMigrationsTests.self)
     let _sourceURL = bundle.url(forResource: "SampleModelV1", withExtension: "sqlite")!  // 125 cars, 5 sport cars
-    
+
     // Being the test run multiple times, we create an unique copy for every test
     let uuid = UUID().uuidString
     let sourceURL = bundle.bundleURL.appendingPathComponent("SampleModelV1_copy-\(uuid).sqlite")
     try FileManager.default.copyItem(at: _sourceURL, to: sourceURL)
     XCTAssertTrue(FileManager.default.fileExists(atPath: sourceURL.path))
-    
+
     let targetVersion = SampleModelVersion.version2
     let steps = SampleModelVersion.version1.migrationSteps(to: .version2)
     XCTAssertEqual(steps.count, 1)
-    
+
     let version = SampleModelVersion(persistentStoreURL: sourceURL)
     XCTAssertTrue(version == .version1)
-    
+
     // When
     let progress = Progress(totalUnitCount: 1)
     var completionSteps = 0

    self.init(concurrencyType: .mainQueueConcurrencyType)
    persistentStoreCoordinator = psc
  }
  
  func _fix_sqlite_warning_when_destroying_a_store() {
    /// solve the warning: "BUG IN CLIENT OF libsqlite3.dylib: database integrity compromised by API violation: vnode unlinked while in use..."
    for store in persistentStoreCoordinator!.persistentStores {

        }
      }
    }

    try CoreDataMigration.migrateStore(from: sourceURL, to: sourceURL, targetVersion: targetVersion)

    XCTAssertEqual(completionSteps, 1)
    XCTAssertEqual(completion, 1.0)

    migratedContext._fix_sqlite_warning_when_destroying_a_store()
    token.invalidate()
  }

  // MARK: - HeavyWeight Migration

  func testMigrationFromVersion2ToVersion3() throws {
    let bundle = Bundle(for: CoreDataMigrationsTests.self)
    let _sourceURL = bundle.url(forResource: "SampleModelV2", withExtension: "sqlite")!

    // Being the test run multiple times, we create an unique copy for every test
    let uuid = UUID().uuidString
    let sourceURL = bundle.bundleURL.appendingPathComponent("SampleModelV2_copy-\(uuid).sqlite")
    try FileManager.default.copyItem(at: _sourceURL, to: sourceURL)
    XCTAssertTrue(FileManager.default.fileExists(atPath: sourceURL.path))

    let targetURL = sourceURL
    let version = SampleModelVersion(persistentStoreURL: sourceURL as URL)

    XCTAssertTrue(version == .version2)

    try CoreDataMigration.migrateStore(from: sourceURL, to: targetURL, targetVersion: SampleModelVersion.version3)

    let migratedContext = NSManagedObjectContext(model: SampleModelVersion.version3.managedObjectModel(), storeURL: targetURL)
    let cars = try migratedContext.fetch(NSFetchRequest<NSManagedObject>(entityName: "Car"))
    let makers = try Maker.fetch(in: migratedContext)
    XCTAssertEqual(makers.count, 11)
    XCTAssertEqual(cars.count, 125)

    cars.forEach { object in
      let owner = object.value(forKey: "owner") as? NSManagedObject
      let maker = object.value(forKey: "createdBy") as? NSManagedObject
