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
c4995884
Commit
c4995884
authored
Jan 04, 2013
by
skandhas
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add test for Module#method_defined?
parent
e6a5a768
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
24 additions
and
0 deletions
+24
-0
test/t/module.rb
test/t/module.rb
+24
-0
No files found.
test/t/module.rb
View file @
c4995884
...
...
@@ -199,6 +199,30 @@ assert('Module#instance_methods', '15.2.2.4.33') do
r
.
class
==
Array
and
r
.
include?
(
:method3
)
and
r
.
include?
(
:method2
)
end
assert
(
'Module#method_defined?'
,
'15.2.2.4.34'
)
do
module
Test4MethodDefined
module
A
def
method1
()
end
end
class
B
def
method2
()
end
end
class
C
<
B
include
A
def
method3
()
end
end
end
Test4MethodDefined
::
A
.
method_defined?
:method1
and
Test4MethodDefined
::
C
.
method_defined?
:method1
and
Test4MethodDefined
::
C
.
method_defined?
"method2"
and
Test4MethodDefined
::
C
.
method_defined?
"method3"
and
not
Test4MethodDefined
::
C
.
method_defined?
"method4"
end
assert
(
'Module#module_eval'
,
'15.2.2.4.35'
)
do
module
Test4ModuleEval
@a
=
11
...
...
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