Class TestDefaults

java.lang.Object
junit.framework.Assert
junit.framework.TestCase
com.martiansoftware.jsap.TestDefaults
All Implemented Interfaces:
junit.framework.Test

public class TestDefaults extends junit.framework.TestCase
Tests JSAP's handling of default values.
Author:
Marty Lamb
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Configures the JSAP object for the tests.
    static junit.framework.Test
    Returns the tests defined in this class.
    void
    Cleans up the JSAP object.
    void
    Ensures that the setUp() method was successful.
    void
    Another test of parameter-level defaults.
    void
    Tests a single level of property defaults.
    void
    Tests JSAP's enforcing of required parameters.
    void
    Tests the parameter-level defaults.

    Methods inherited from class junit.framework.TestCase

    assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, countTestCases, fail, fail, failNotEquals, failNotSame, failSame, format, getName, run, run, runBare, setName, toString

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • TestDefaults

      public TestDefaults()
  • Method Details

    • suite

      public static junit.framework.Test suite()
      Returns the tests defined in this class.
      Returns:
      the tests defined in this class.
    • testConfig

      public void testConfig()
      Ensures that the setUp() method was successful.
    • testSimpleDefault

      public void testSimpleDefault()
      Tests the parameter-level defaults.
    • testDefaults2

      public void testDefaults2()
      Another test of parameter-level defaults.
    • testRequired

      public void testRequired()
      Tests JSAP's enforcing of required parameters.
    • testOneLevelDefaults

      public void testOneLevelDefaults()
      Tests a single level of property defaults.
    • setUp

      public void setUp() throws JSAPException
      Configures the JSAP object for the tests.
      Throws:
      JSAPException - if the JSAP object cannot be instantiated.
    • tearDown

      public void tearDown()
      Cleans up the JSAP object.