Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mruby
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Libraries
mruby
Commits
4f4e2400
Unverified
Commit
4f4e2400
authored
Jun 28, 2019
by
Yukihiro "Matz" Matsumoto
Committed by
GitHub
Jun 28, 2019
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #4538 from shuujii/use-__ENCODING__-in-tests
Use `__ENCODING__` in tests
parents
cf7a2292
bc3176da
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
3 deletions
+3
-3
mrbgems/mruby-string-ext/test/string.rb
mrbgems/mruby-string-ext/test/string.rb
+1
-1
mrbgems/mruby-symbol-ext/test/symbol.rb
mrbgems/mruby-symbol-ext/test/symbol.rb
+1
-1
test/t/string.rb
test/t/string.rb
+1
-1
No files found.
mrbgems/mruby-string-ext/test/string.rb
View file @
4f4e2400
...
...
@@ -2,7 +2,7 @@
##
# String(Ext) Test
UTF8STRING
=
(
"
\343\201\202
"
.
size
==
1
)
UTF8STRING
=
__ENCODING__
==
"UTF-8"
assert
(
'String#getbyte'
)
do
str1
=
"hello"
...
...
mrbgems/mruby-symbol-ext/test/symbol.rb
View file @
4f4e2400
...
...
@@ -14,7 +14,7 @@ end
assert
(
"Symbol#
#{
n
}
"
)
do
assert_equal
5
,
:hello
.
__send__
(
n
)
assert_equal
4
,
:"aA
\0
b"
.
__send__
(
n
)
if
"あ"
.
size
==
1
# enable MRB_UTF8_STRING?
if
__ENCODING__
==
"UTF-8"
assert_equal
8
,
:"こんにちは世界!"
.
__send__
(
n
)
assert_equal
4
,
:"aあ
\0
b"
.
__send__
(
n
)
else
...
...
test/t/string.rb
View file @
4f4e2400
...
...
@@ -2,7 +2,7 @@
##
# String ISO Test
UTF8STRING
=
(
"
\343\201\202
"
.
size
==
1
)
UTF8STRING
=
__ENCODING__
==
"UTF-8"
assert
(
'String'
,
'15.2.10'
)
do
assert_equal
Class
,
String
.
class
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment