how to test local interface entitybean?

Discussions

EJB design: how to test local interface entitybean?

  1. how to test local interface entitybean? (3 messages)

    how to test local interface entitybean?
    you'd better answer the question with code,thank you.
  2. how to test local interface entitybean?[ Go to top ]

    http://jakarta.apache.org/cactus/index.html

    It comes with code examples!
  3. how to test local interface entitybean?[ Go to top ]

    thanks for your reply, i read the content about cactus ,but the test example is only for remote interface.
  4. Hi!

    First of all, in any real test you should not test local beans directly. You should treat an EJB jar as one unit and test it's behaviour from an external client's point of view.

    On the other hand, you will need tests during development! (I mean the informal test made by the programmer. Not formal tests in a project.) My proposal is to deploy another (non-local) bean, test that one and the assume it works when deployed as a local bean. I think (but don't remember the details from the spec) that you will need two different remove interfaces: The remove one throwing RemoteException and the local one without RemoteException. Besides this difference, the two interfaces are the same.

    /Tomas