         XCTAssert(diff.movements == Set([DiffMatch(0, 1)]))
         XCTAssert(diff.matches == Set([DiffMatch(0, 1), DiffMatch(1, 0), DiffMatch(2, 2)]))
     }
+    
+    func testInsertionDeletion() {
+        let a = [0]
+        let b = [1, 2]
+        
+        let diff = Diff(from: a, to: b)
+        
+        XCTAssert(diff.inserted == IndexSet(0...1))
+        XCTAssert(diff.deleted == IndexSet(0...0))
+        XCTAssert(diff.movements.count == 0)
+        XCTAssert(diff.matches.count == 0)
+    }
 }

        
        let diff = Diff(from: a, to: b)
        
        XCTAssert(diff.inserted == IndexSet(integersIn: 1...2))
        XCTAssert(diff.deleted.count == 0)
        XCTAssert(diff.movements.count == 0)
        XCTAssert(diff.matches == Set([DiffMatch(0)]))

        let diff = Diff(from: a, to: b)
        
        XCTAssert(diff.inserted.count == 0)
        XCTAssert(diff.deleted == IndexSet(1...2))
        XCTAssert(diff.movements.count == 0)
        XCTAssert(diff.matches == Set([DiffMatch(0)]))
    }
