From cb9d3b1a2c2c59c368f6121a16a9ab928b0ff951 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Sun, 23 Nov 2025 00:35:05 -0500 Subject: Added Text.find(text, target, start=1) --- test/text.tm | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'test/text.tm') diff --git a/test/text.tm b/test/text.tm index 094da8f8..6c23042d 100644 --- a/test/text.tm +++ b/test/text.tm @@ -202,3 +202,9 @@ func main() assert Text.from_utf32([150370]) == test assert Text.from_utf16([-10158, -8350]) == test assert Text.from_utf8([0xf0, 0xa4, 0xad, 0xa2]) == test + + + assert "one two".find("one") == 1 + assert "one two".find("two") == 5 + assert "one two".find("three") == none + assert "one two".find("o", start=2) == 7 -- cgit v1.2.3