Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Some additional Event tests and simplifications.
git-svn-id: http://anonsvn.jboss.org/repos/weld/ri/trunk@478 1c488680-804c-0410-94cd-c6b725194a0e
- Loading branch information
Showing
3 changed files
with
123 additions
and
181 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 23 additions & 0 deletions
23
webbeans-ri/src/test/java/org/jboss/webbeans/test/beans/BananaSpider.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
package org.jboss.webbeans.test.beans; | ||
|
||
import java.util.Set; | ||
|
||
import javax.webbeans.Observer; | ||
import javax.webbeans.Observes; | ||
import javax.webbeans.manager.Manager; | ||
|
||
/** | ||
* Simple bean with observer method and another injectable parameter. | ||
* | ||
*/ | ||
public class BananaSpider | ||
{ | ||
public void observeStringEvent(@Observes String someEvent, Manager manager) | ||
{ | ||
assert someEvent != null; | ||
assert manager != null; | ||
Set<Observer<String>> allStringObservers = manager.resolveObservers(someEvent); | ||
assert allStringObservers != null; | ||
assert allStringObservers.size() > 0; | ||
} | ||
} |
Oops, something went wrong.