Using Services when unit testing plugin against Idea 2019.3

Answered

Hi,

We are trying to expand the testing regime for our plugin to cover all versions that we support, including 2019.3. Some of our tests, based on `

JavaModuleTestCase

make calls to

ServiceManager.getService

However this always seems to return null for our own service classes (annotated with

@State

and implementing

PersistentStateComponent

). This works fine since Idea 2020.X. Is this some known limitation for 2019.3? Would there be any relatively pain-free workaround?

Thanks!
Scott

2 comments
Comment actions Permalink

I'll see if I can produce a minimum example for this. Thanks!

0

Please sign in to leave a comment.