Skip to Content.
Sympa Menu

shibboleth-dev - RE: Integration JUnit testing

Subject: Shibboleth Developers

List archive

RE: Integration JUnit testing


Chronological Thread 
  • From: "Howard Gilbert" <>
  • To: <>
  • Subject: RE: Integration JUnit testing
  • Date: Fri, 26 Aug 2005 12:35:12 -0400



> I don't understand how you intend to test the AA separate from the SSO
> service. What NameIdentifier will you send the AA in the attribute
> query?

You don't. The current test case creates Mock objects and calls the SSO.
However, it currently requires Attribute Push.

If you add the second block of code to mock the AA query, then you can use
the non-push method. The Mock SSO call generates an Assertion, the SP code
consumes the Assertion and generates an attribute query that goes through
the Mock binding directly to the AA. This produces a complete end to end
test of the protocol elements without any Web Server. In one version a
single set of Mockrunner objects is created and reused, but an alternate
approach creates two sets of objects, one for the SSO Servlet call and one
for the AA Servlet call. That is a detail.

The test can be broken up into pieces, so that results can be tested by
JUnit assert statements after each step. However, since you cannot make a
query without an SSO, the original assertion either has to be saved or else
after one SSO is tested for accuracy, a second test would do a second SSO
and then plug right on to the query. The effect may be a "12 days of
Christmas" test where each subsequent test repeats the previous one and then
adds one additional element.

Because the results can only be determined upon return to the TestCase, it
may be necessary to add flags at strategic places that can be turned on in
the test environment to cause intermediate results to be published and then
a return be made.





Archive powered by MHonArc 2.6.16.

Top of Page