Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jakartaee-tck-dev] Jakarta Authentication TCK

Hi,

On Tue, Mar 29, 2022 at 12:59 AM Olivier Lamy <olamy@xxxxxxxxxxx> wrote:

Where are those javatest tests in the current TCK source tree?


The interesting thing is that at least a while back (but I think it might still be the case), you could make a build of your server to not actually authenticate (remove the part in your server code where it sets the authentication result), and the TCK would still happily pass.

(I have started some work for servlet by scanning those javadoc annotations to generate some files to execute tests using junit5 TestEngine)
I'm trying to find a way to execute all tests all together when an implementation wants to execute various tests.
Ideally it should be simple with using some surefire configuration such and such project will run all provided TCK tests on the provided arquillian container :

I think Manfred Riem was working on something that sounded a little like that. See https://github.com/manorrock/mammoth

An intermediate solution is to run an existing TCK during a Maven build via something like this: 


Obviously such a run doesn't use the provider arquillian container. 

Kind regards,
Arjan

 


<dependencies>
    ......
    <dependency>
      <groupId>jakartatck</groupId>
      <artifactId>servlet</artifactId>
      <version>${jakarta.tck.version}</version>
    </dependency>
    <dependency>
      <groupId>jakartatck</groupId>
      <artifactId>jsp</artifactId>
      <version>${jakarta.tck.version}</version>
    </dependency>    
    <dependency>
      <groupId>jakartatck</groupId>
      <artifactId>websocket</artifactId>
      <version>${jakarta.tck.version}</version>
    </dependency>    
    <dependency>
      <groupId>jakartatck</groupId>
      <artifactId>authentication</artifactId>
      <version>${jakarta.tck.version}</version>
    </dependency>        
    <dependency>
      <groupId>org.jboss.arquillian.container</groupId>
      <artifactId>your container</artifactId>
      <version></version>
      <scope>test</scope>
    </dependency>
    ....
  </dependencies>

        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-surefire-plugin</artifactId>
          <version>${surefire.version}</version>        
          <configuration>
            .......
            <includeJUnit5Engines>
              <includeJUnit5Engine>jakarta-tck-test-engine</includeJUnit5Engine>
            </includeJUnit5Engines>
            <excludeJUnit5Engines>
              <excludeJUnit5Engine>junit-vintage</excludeJUnit5Engine>
              <excludeJUnit5Engine>junit-jupiter</excludeJUnit5Engine>
            </excludeJUnit5Engines>
            <dependenciesToScan>
              <dependenciesToScan>jakartatck:servlet</dependenciesToScan>
              <dependenciesToScan>jakartatck:jsp</dependenciesToScan>
              <dependenciesToScan>jakartatck:websocket</dependenciesToScan>
              <dependenciesToScan>jakartatck:authentication</dependenciesToScan>
              .....
            </dependenciesToScan>
            <includes>
              <include>**/URLClient*</include>
              <include>**/Client*</include>
            </includes>
          </configuration>
        </plugin>

 

The new tests function much like Servlet tests; it's a war file with a protected Servlet, a ServerAuthModule is then included as well, the war is deployed, and via HTTP requests it's tested whether and under what conditions the protected Servlet can be reached.

I've never been entirely sure what the javatest based TCK exactly tests (I should investigate this still). I guess it's doing some scanning to see if the right classes are present on the classpath or something in that direction, but AFAIK it doesn't test the core of Jakarta Authentication, which is to test whether authentication is actually done by a server. The new tests do test that.

Kind regards,
Arjan

 

On Tue, Mar 29, 2022 at 7:50 AM arjan tijms <arjan.tijms@xxxxxxxxx> wrote:
Hi,

The Jakarta Authentication project has been working on newTCK  tests based on Arquillian. The current version can be found here: https://github.com/jakartaee/authentication/tree/master/tck


We'd like to request help to finalize this TCK and have it called from the platform TCK.

Kind regards,
Arjan
_______________________________________________
jakartaee-tck-dev mailing list
jakartaee-tck-dev@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/jakartaee-tck-dev


--
Olivier
_______________________________________________
jakartaee-tck-dev mailing list
jakartaee-tck-dev@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/jakartaee-tck-dev
_______________________________________________
jakartaee-tck-dev mailing list
jakartaee-tck-dev@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/jakartaee-tck-dev


--
Olivier
_______________________________________________
jakartaee-tck-dev mailing list
jakartaee-tck-dev@xxxxxxxxxxx
To unsubscribe from this list, visit https://www.eclipse.org/mailman/listinfo/jakartaee-tck-dev

Back to the top