Class EPPLaunchPolicyRegistryTst

java.lang.Object
junit.framework.Assert
junit.framework.TestCase
com.verisign.epp.interfaces.launchpolicy.v01.EPPLaunchPolicyRegistryTst
All Implemented Interfaces:
junit.framework.Test

public class EPPLaunchPolicyRegistryTst extends junit.framework.TestCase
  • Constructor Summary

    Constructors
    Constructor
    Description
    Allocates an EPPLaunchPolicyRegistryTst with a logical name.
  • Method Summary

    Modifier and Type
    Method
    Description
    Build a populated EPPLaunchPolicyZone instance that can be included in one of the Launch Policy Extensions.
    void
    Handle an EPPCommandException, which can be either a server generated error or a general exception.
    Make a pseudo random zone name.
    void
    registryCheck(Map aZoneNames)
    Unit test of EPPRegistry.sendCheck.
    void
    registryCreate(String aZoneName, boolean aShouldSucceed)
    Unit test of EPPRegistry.sendCreate.
    void
    registryDelete(String aZoneName, boolean aShouldSucceed)
    Unit test of EPPRegistry.sendDelete.
    void
    Test for the registry info command that supports the three forms of getting detailed information for an individual zone by setting the aZoneName parameter to a non-null value, getting a summary of all zones by setting the aScope parameter to a non-null value, and getting the system information by setting the aSystem parameter to true.
    void
    registryUpdate(String aZoneName, boolean aShouldSucceed)
    Unit test of EPPRegistry.sendUpdate.
    protected void
     
    static junit.framework.Test
     
    protected void
    JUNIT tearDown, which currently does nothing.
    void
    Test the Registry Mapping by doing the following: Create a set of zones. Update a zone. Check the availability (existence) of the zones. Get all summary information for the zones. Get detailed zone information for some zones. Get registry system information. Delete a set of zones.

    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, createResult, fail, fail, failNotEquals, failNotSame, failSame, format, getName, run, run, runBare, runTest, setName, toString

    Methods inherited from class java.lang.Object

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

    • EPPLaunchPolicyRegistryTst

      public EPPLaunchPolicyRegistryTst(String name)
      Allocates an EPPLaunchPolicyRegistryTst with a logical name. The constructor will initialize the base class TestCase with the logical name.
      Parameters:
      name - Logical name of the test
  • Method Details

    • testRegistry

      public void testRegistry()
      Test the Registry Mapping by doing the following:
      1. Create a set of zones.
      2. Update a zone.
      3. Check the availability (existence) of the zones.
      4. Get all summary information for the zones.
      5. Get detailed zone information for some zones.
      6. Get registry system information.
      7. Delete a set of zones.
    • registryCheck

      public void registryCheck(Map aZoneNames)
      Unit test of EPPRegistry.sendCheck.
      Parameters:
      aZoneNames - Names of the zones to check
    • registryCreate

      public void registryCreate(String aZoneName, boolean aShouldSucceed)
      Unit test of EPPRegistry.sendCreate.
      Parameters:
      aZoneName - Zone to create
      aShouldSucceed - true if the zone create should succeed; false otherwise.
    • registryDelete

      public void registryDelete(String aZoneName, boolean aShouldSucceed)
      Unit test of EPPRegistry.sendDelete.
      Parameters:
      aZoneName - Zone to delete
      aShouldSucceed - true if the zone delete should succeed; false otherwise.
    • registryUpdate

      public void registryUpdate(String aZoneName, boolean aShouldSucceed)
      Unit test of EPPRegistry.sendUpdate.
      Parameters:
      aZoneName - Zone to update
      aShouldSucceed - true if the zone update should succeed; false otherwise.
    • registryInfo

      public void registryInfo(EPPRegistryInfoCmd.Mode aMode, String aZoneName, EPPRegistryInfoCmd.Scope aScope)
      Test for the registry info command that supports the three forms of getting detailed information for an individual zone by setting the aZoneName parameter to a non-null value, getting a summary of all zones by setting the aScope parameter to a non-null value, and getting the system information by setting the aSystem parameter to true. There can be only one form used as a time.
      Parameters:
      aMode - One of the support info modes ( EPPRegistryInfoCmd.Mode.name, EPPRegistryInfoCmd.Mode.all, or EPPRegistryInfoCmd.Mode.system)
      aZoneName - Used with the "name" info mode that represents the zone name to query. Set to null with the EPPRegistryInfoCmd.Mode.all or EPPRegistryInfoCmd.Mode.system modes.
      aScope - Used with the "all" info mode that represents the scope of the zones to query. Set to null with the EPPRegistryInfoCmd.Mode.name or EPPRegistryInfoCmd.Mode.system modes.
    • makeZoneName

      public String makeZoneName()
      Make a pseudo random zone name.
      Returns:
      pseudo random zone name
    • handleException

      public void handleException(Exception aException)
      Handle an EPPCommandException, which can be either a server generated error or a general exception. If the exception was caused by a server error, "Server Error :<Response XML>" will be specified. If the exception was caused by a general algorithm error, "General Error :<Exception Description>" will be specified.
      Parameters:
      aException - Exception thrown during test
    • suite

      public static junit.framework.Test suite()
    • setUp

      protected void setUp()
      Overrides:
      setUp in class junit.framework.TestCase
    • tearDown

      protected void tearDown()
      JUNIT tearDown, which currently does nothing.
      Overrides:
      tearDown in class junit.framework.TestCase
    • buildLaunchPolicyZone

      public static EPPLaunchPolicyZone buildLaunchPolicyZone()
      Build a populated EPPLaunchPolicyZone instance that can be included in one of the Launch Policy Extensions. The populated attributes are based on the sample included in draft-gould-regext-launch-policy. The following phases are added to the populated EPPLaunchPolicyZone instance:
      1. Sunrise
      2. Claims for Limited Registration Period #1 (LRP1)
      3. Claims for Landrush
      4. Claims (Open)
      5. Custom for Limited Registration Period #2 (LRP2)
      6. Open
      Returns:
      Populated EPPLaunchPolicyZone based on the sample included in draft-gould-regext-launch-policy.