Skip to content

Commit

Permalink
upgraded method param name test to include reference to local variabl…
Browse files Browse the repository at this point in the history
…e as well as method params
  • Loading branch information
adinn committed Jul 9, 2012
1 parent eee3ad2 commit 2e744b3
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,14 @@ public void test()

public void callWithNamedParams(String bar, String baz)
{
log("inside foo() " + this + " " + bar + " " + baz);
String fred = "fred";
log("inside foo() " + this + " " + bar + " " + baz + " " + fred);
}

@Override
public String getExpected() {
logExpected("injected foo() " + this + " bar baz");
logExpected("inside foo() " + this + " bar baz");
logExpected("injected foo() " + this + " bar baz fred");
logExpected("inside foo() " + this + " bar baz fred");

return super.getExpected();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ RULE test use of method param names
CLASS TestMethodParamName
METHOD callWithNamedParams
# HELPER org.jboss.byteman.tests.helpers.Default
AT ENTRY
AT CALL log
BIND test : TestMethodParamName = $0
IF TRUE
DO test.log("injected foo() " + $this + " " + $bar + " " + $baz)
DO test.log("injected foo() " + $this + " " + $bar + " " + $baz + " " + $fred)
ENDRULE

0 comments on commit 2e744b3

Please sign in to comment.