Open jerseyrobot opened 8 years ago
@glassfishrobot Commented Reported by egore911
@glassfishrobot Commented @pavelbucek said: What about GrizzlyWebServletAndFilterTest ?
In general, you can't use ServletDeploymentContext on non servlet containers. GrizzlyTestConatiner and InMemoryTest container are NOT servlet containers. The only one is GrizzlyWebTestContainer/GrizzlyWebTestContainerFactory..
@glassfishrobot Commented egore911 said: I added the following to my test:
protected TestContainerFactory getTestContainerFactory() {
return new GrizzlyWebTestContainerFactory();
}
This makes my code work. Thanks for the hints.
@glassfishrobot Commented This issue was imported from java.net JIRA JERSEY-3096
I have the following test class:
Plus the following filter
If been looking through the code and couldn't find any place where the fitler I added would be read. I would have expected it to be read in GrizzlyTestContainerFactory#GrizzlyTestContainer, JettyTestContainerFactory#JettyTestContainer or InMemoryTestContainerFactory#InMemoryTestContainer.
Looks like this feature was not used so far and is not implemented yet.
Affected Versions
[2.22.1]