chore: rename test files to snake_case and update string class docs
Rename indexOf.wren and startsWith.wren test files to index_of.wren and starts_with.wren respectively, fix missing trailing newlines, update string class documentation to clarify UTF-8 storage and move the note about incorrect UTF-8 handling in the index operator, and remove unnecessary parentheses in string_indexOf native return.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
IO.print("abcd".indexOf("cd")) // expect: 2
|
||||
IO.print("abcd".indexOf("a")) // expect: 0
|
||||
IO.print("abcd".indexOf("abcde")) // expect: -1
|
||||
IO.print("abab".indexOf("ab")) // expect: 0
|
||||
IO.print("abab".indexOf("ab")) // expect: 0
|
||||
@@ -1 +1 @@
|
||||
IO.print("abcd".indexOf(null)) // expect runtime error: Argument must be a string.
|
||||
IO.print("abcd".indexOf(null)) // expect runtime error: Argument must be a string.
|
||||
@@ -2,4 +2,4 @@ IO.print("abcd".startsWith("cd")) // expect: false
|
||||
IO.print("abcd".startsWith("a")) // expect: true
|
||||
IO.print("abcd".startsWith("abcd")) // expect: true
|
||||
IO.print("abcd".startsWith("abcde")) // expect: false
|
||||
IO.print("abcd".startsWith("")) // expect: true
|
||||
IO.print("abcd".startsWith("")) // expect: true
|
||||
@@ -1 +1 @@
|
||||
IO.print("abcd".startsWith(null)) // expect runtime error: Argument must be a string.
|
||||
IO.print("abcd".startsWith(null)) // expect runtime error: Argument must be a string.
|
||||
Reference in New Issue
Block a user