Skip to content
This repository was archived by the owner on Apr 13, 2023. It is now read-only.

TCK_Contributors_Guide

Scott Kurz edited this page Oct 5, 2015 · 4 revisions

Guide for contributing a new TCK test (at least an outline of a guide)

Some Basic Test Structure

  • The typical test method begins by submitting a job via JobOperator#start.

    • There is no order of execution assumed among the tests, so to do pretty much anything requires a job to have run within the test method.

  • In general, the validation logic (i.e. the check for success/failure) is either performed:

    • within the TestNG test method at various points within the sequence of calls to the job repository (i.e. to JobOperator).

    • OR within the job execution (i.e. within the batch artifacts themselves)

    • OR within some combination of both.

  • The tests use the JobOperatorBridge utility provided by the TCK in order to encapsulate the waiting for "termination" (i.e. waiting for COMPLETED, FAILED, or STOPPED).

  • Any test with any sort of wait introducing a timing dependency will include a specific, well-documented system property for each individual wait, in each individual test, to allow the executor to tune for his particular implementation and environment. A hopefully well-chosen default value will be hard-coded as well.

What files make up a single test?

  1. First, the TestNG test method

    • Annotated with @Test (imported from org.testng.annotations)

    • Also annotated with @org.junit.Test

    • Using

Checklist

a *com.ibm.jbatch.tck.tests*

, @Test annotations - logging - bridge, - waiter - annotation - timeout (if necessary) * JSL * artifacts (impls of JSR 352) com.ibm.jbatch.tck.artifacts

  • batch.xml

  • update TestNG suite (if necessary)

  • Maven

  • bugzilla

  • RI/spec

Clone this wiki locally