It is written in the Guice best practices guide that modules should be 
tested.
I fully agree with you. 

However and this is something I was not able to find on the Web: when I 
have a module B installing another module A, how can I test module B.

On top of it I have the following situation using mybatis-guice library:

ModuleA extends AbstractModule {
  @Override protected void configure() {
    bind(a.class).to(aImpl.class);
    ....
    install(new ModuleB());
    install(new DbModule());
    ....
  }
}

ModuleB extends AbstratModule {
  ....
  bind(b.class).to(bImpl.class);
  install(...);
  ...
}

DbModule extends PrivateModule {
  ...
  install(new MyBatisModule() ....);
  expose(Mapper1.class);
  ...
}

Would you have any advice on what are the best practices to test all these 
modules?

-- 
You received this message because you are subscribed to the Google Groups 
"google-guice" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-guice.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to