From 67f7a5e9eba1e97b975b2d5cd8a29aef404f9149 Mon Sep 17 00:00:00 2001 From: Ekaitz Zarraga Date: Tue, 9 Jan 2024 22:30:26 +0100 Subject: par: piece-table: delete operation --- tests/piece-table.scm | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'tests/piece-table.scm') diff --git a/tests/piece-table.scm b/tests/piece-table.scm index 04a62bc..b8b6ff1 100644 --- a/tests/piece-table.scm +++ b/tests/piece-table.scm @@ -22,4 +22,11 @@ (test-end "insert") (test-begin "delete") + (define table (make-piece-table "HOLA SOY EKAITZ")) + (piece-table-delete! table 4) + (test-equal "HOLASOY EKAITZ" (piece-table->string table)) + (piece-table-delete! table 0) + (test-equal "OLA SOY EKAITZ" (piece-table->string table)) + (piece-table-delete! table 13) + (test-equal "OLA SOY EKAIT" (piece-table->string table)) (test-end "delete") -- cgit v1.2.3