TestCompilerDef (cpptasks 1.0b5 Test API)
Keywords: net.sf.antcontrib.cpptasks.TestCompilerDef class

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## net.sf.antcontrib.cpptasks
Class TestCompilerDef

    java.lang.Object
      junit.framework.Assert
          junit.framework.TestCase
              net.sf.antcontrib.cpptasks.TestProcessorDef
                  net.sf.antcontrib.cpptasks.TestCompilerDef

All Implemented Interfaces:
  junit.framework.Test

    public final class TestCompilerDef

extends TestProcessorDef

Tests for CompilerDef.

Constructor Summary
`TestCompilerDef(java.lang.String name)` Constructor.

Method Summary
`protected net.sf.antcontrib.cpptasks.ProcessorDef` | `create()` Creates a new processor.
`protected java.lang.String[]` | `getPreArguments(net.sf.antcontrib.cpptasks.ProcessorDef processor)` Gets the command line arguments that precede filenames.
`void` | `testExtendsClassname()` Tests that the classname attribute in the base compiler is effective.
`void` | `testExtendsCompilerArgs()` Tests that compilerarg's contained in the base compiler definition are effective.
`void` | `testExtendsDefineSet()` Tests that defineset's contained in the base compiler definition are effective.
`void` | `testExtendsExceptions()` Tests that the extend attribute of the base compiler definition is effective.
`void` | `testExtendsFileSet()` Tests if a fileset enclosed in the base compiler definition is effective.
`void` | `testExtendsIncludePath()` Tests that includepath's contained in the base compiler definition are effective.
`void` | `testExtendsMultithreaded()` Tests that the multithread attribute of the base compiler definition is effective.
`void` | `testExtendsName()` Tests that the name attribute in the base compiler is effective.
`void` | `testExtendsRebuild()` Tests if the rebuild attribute of the base compiler definition is effective.
`void` | `testExtendsSysIncludePath()` Tests that sysincludepath's contained in the base compiler definition are effective.
`void` | `testGetActiveDefines()` This method tests CompilerDef.getActiveDefines.
`void` | `testGetActiveIncludePaths()` This method tests CompilerDef.getActiveIncludePath.
`void` | `testGetGcc()` Tests that setting classname to the Gcc compiler is effective.
`void` | `testGetMSVC()` Tests that setting classname to the MSVC compiler is effective.
`void` | `testUnknownClass()` Tests that setting classname to an bogus class name results in a BuildException.
`void` | `testWrongType()` Test that setting classname to a class that doesn't support Compiler throws a BuildException.

Methods inherited from class net.sf.antcontrib.cpptasks.TestProcessorDef
`createExtendedProcessorDef, getConfiguration, testExtendsDebug, testExtendsFileSet, testExtendsIf, testExtendsRebuild, testExtendsUnless, testIsActive2, testIsActive3, testIsActive4, testIsActive5, testIsActive6, testIsActive7, testIsActive8`

Methods inherited from class junit.framework.TestCase
`countTestCases, createResult, getName, run, run, runBare, runTest, setName, setUp, tearDown, toString`

Methods inherited from class junit.framework.Assert
`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, fail, fail`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Constructor Detail

### TestCompilerDef

    public TestCompilerDef(java.lang.String name)

  Constructor.

  Parameters:
    `name` - test name

Method Detail

### create

    protected net.sf.antcontrib.cpptasks.ProcessorDef create()

  Creates a new processor.

  Specified by:
    `create` in class `TestProcessorDef`
  Returns:
    new processor

### testGetActiveDefines

    public void testGetActiveDefines()

  This method tests CompilerDef.getActiveDefines. A CompilerDef is created similar to what would be created for Then getActiveDefines is called for a project without and with the "debug" property defined. Return value from getActiveDefines should contain one member

### testGetActiveIncludePaths

    public void testGetActiveIncludePaths()

  This method tests CompilerDef.getActiveIncludePath. A CompilerDef is created similar to what would be created for and is evaluate for a project without and without "debug" set

### testGetGcc

    public void testGetGcc()

  Tests that setting classname to the Gcc compiler is effective.

### testGetMSVC

    public void testGetMSVC()

  Tests that setting classname to the MSVC compiler is effective.

### testUnknownClass

    public void testUnknownClass()

  Tests that setting classname to an bogus class name results in a BuildException.

### testWrongType

    public void testWrongType()

  Test that setting classname to a class that doesn't support Compiler throws a BuildException.

### getPreArguments

    protected java.lang.String[] getPreArguments(net.sf.antcontrib.cpptasks.ProcessorDef processor)

  Gets the command line arguments that precede filenames.

  Specified by:
    `getPreArguments` in class `TestProcessorDef`
  Parameters:
    `processor` - processor under test
  Returns:
    command line arguments

### testExtendsFileSet

    public void testExtendsFileSet()
                            throws java.io.IOException

  Tests if a fileset enclosed in the base compiler definition is effective.

  Throws:
    `java.io.IOException` - if unable to create or delete a temporary file

### testExtendsRebuild

    public void testExtendsRebuild()

  Tests if the rebuild attribute of the base compiler definition is effective.

### testExtendsCompilerArgs

    public void testExtendsCompilerArgs()

  Tests that compilerarg's contained in the base compiler definition are effective.

### testExtendsDefineSet

    public void testExtendsDefineSet()

  Tests that defineset's contained in the base compiler definition are effective.

### testExtendsIncludePath

    public void testExtendsIncludePath()

  Tests that includepath's contained in the base compiler definition are effective.

### testExtendsSysIncludePath

    public void testExtendsSysIncludePath()

  Tests that sysincludepath's contained in the base compiler definition are effective.

### testExtendsExceptions

    public void testExtendsExceptions()

  Tests that the extend attribute of the base compiler definition is effective.

### testExtendsMultithreaded

    public void testExtendsMultithreaded()

  Tests that the multithread attribute of the base compiler definition is effective.

### testExtendsName

    public void testExtendsName()

  Tests that the name attribute in the base compiler is effective.

### testExtendsClassname

    public void testExtendsClassname()

  Tests that the classname attribute in the base compiler is effective.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2001-2008 Ant-Contrib Project. All Rights Reserved.