FlexUnit + AIR + Ant?

Is the ant <flexunit> task compatible with AIR?
My AIR app uses a SQLite database and some of my integration tests will create a sample database and needs to use the File object in the AIR SDK.  I can compile fine by including the AIR libraries, but when I run the tests in the TestRunner, I get a bunch of AIR related error messages and I get a socket timeout while waiting for the reports message.  These could be separate issues, but I want to make sure what I'm doing is possible with this tool.
Here's a sampling of my ant targets if it helps...
    <target name="compile.tests">
        <echo>Compiling Jars Test Cases</echo>
        <mkdir dir="${reports.dir}/tests" />
        <mxmlc
            file="${test.src}/${test.app.name}.mxml"
            output="${test.bin}/${test.app.name}.swf"
            actionscript-file-encoding="UTF-8"
            keep-generated-actionscript="false"
            incremental="false"
            locale="en_US"
            use-network="false"
            warnings="false"
            configname="air">
            <source-path path-element="${test.src}" />
            <source-path path-element="src/locales/{locale}" />
            <library-path dir="${FLEX_HOME}/frameworks/libs/air" append="true">
                <include name="*.swc" />
            </library-path> 
            <library-path dir="${FLEX_HOME}/frameworks/libs" append="true">
                <include name="*.swc" />
            </library-path>
            <library-path dir="${FLEX_HOME}/frameworks/locale" append="true">
                <include name="*.swc" />
            </library-path>
            <library-path dir="${test.lib}" append="true">
                <include name="*.swc" />
            </library-path>
        </mxmlc> 
    </target>
     <target name="unit.tests">   
        <echo>Running unit tests...</echo>
        <flexunit
            swf="${test.bin}/${test.app.name}.swf"
            todir="${reports.dir}/tests"
            haltonfailure="false"
            verbose="true"
            localTrusted="true"
            failureproperty="failedtests" />
        <junitreport todir="${reports.dir}/tests">
            <fileset dir="${reports.dir}/tests">
                <include name="TEST-*.xml"/>
            </fileset>
            <report format="frames" todir="${reports.dir}/tests"/>
        </junitreport>

looks like something was submitted in the new Git repo, I grabbed it several days ago (11/18 i think?) and was able to get it working... but it's not bug free. Issues I had:
1. on windows it's trying to run adl.bat. There is no adl.bat in the sdk, only adl.exe. Easy to fix, I just made a batch file that pointed to adl.exe. I suppose you could just change the executable name, but I didn't feel like changing the flexunit code base.
2. it won't close the test project when the test run completes. I see the logic to do so, but it either isn't firing, or is firing but not working. I was able to solve this by adding a timer to perform a delayed application exit in my testlib mxml, which will work as a band-aid until it can be fixed properly.
Perhaps these issues have been resolved since I last looked, haven't had time to go back and dig into it since I got it working.

Similar Messages

  • Mounting Information AP-Bracket-2 and Air-Ant-2566P4W-R

    Hello,
    for mounting preparation I need information about
    hole-size and hole pitch (position / distance between holes)
    for AP-Bracket-2 and ANT-2566P4W.
    I can't find this information (installation guides).
    Regards
    Sven

    The hole size is mentioned in the docs, but you will not find the drawing with the hole spacing anywhere. You would need one of each as a template to be 100% sure.
    Sent from Cisco Technical Support iPhone App

  • Can not run flexunit tests from ant

    Hello,
    I'm trying to script test execution in order to integrate tests in Jenkins. I followed the wiki article here http://docs.flexunit.org/index.php?title=Ant_Task
    The tests run successfully with Flash Builder but not with ant. I'm getting the following error:
    Error
    VerifyError: Error #1014: The class flash.filesystem::FileStream could not be found
    I think that this occurs because I'm using the flashplayer_11 as suggested in the wiki article and flashplayer does not load the airglobal.swc component.
    I noticed that Flash Builder launches the ADL.exe process; whereas flexunit within ant tests launches flashplayer.exe.
    Should I use ADL.exe with flexunit instead of Flash player ? In that case how to use adl argument in flexunnit ? I saw that Richard Lee has committed a fix to make flexunit support ADL arguments, how ?
    Is there a solution to my problem ?
    Thanks in advance.
    Ygor

    Thank you Michael,
    I resolved my problem by adding the the player attribute in the flexunit task as follow:
    <flexunit
               player="air"
                workingDir="${bin.loc}"
                toDir="${report.loc}"
                haltonfailure="false"
                verbose="true"
                localTrusted="true"
                >

  • Generate HTML report with ANT

    Hello,
    I'm  new to FlexPMD. I have just generated my firsts reports. I try to generate HTML reports.
    I browse the documentation, this forum and the web and I find informations to :
    - generate documentation with Hudson
    - generate documentation with Maven
    - generate documentation with XSLT pmd.xml -> html
    Ok, I try to keep it simple. So I don't want to use Hudson.
    I'm using ANT, and I currently don't want to install/learn Maven.
    I'm using FlexUnit with ANT. And It's really simple to generate reports :
    <junitreport todir="${report.flexunit.loc}">
                <fileset dir="${report.flexunit.loc}">
                    <include name="TEST-*.xml" />
                </fileset>
                <report format="frames" todir="${report.flexunit.loc}/html" />
    </junitreport>
    I'm really new to FlexPMD, so I don't have currently a big knowledge, but it seems impossible to generate a HTML report just like junitreport. (1 line in an ANT task)
    I test the XSLT transformation found on this forum (thread "XSLT pmd.xml -> html"). It's really cool. But it's seems difficult, for example, to extract the wrong code part and add it to the HTML page.
    So, what is the simpler solution to generate HTML report just with FlexPMD/ANT ?
    Thanks !

    Hello,
    Currently you generate a PMD report with ANT  like this :
    <! -- define taskdef  -->
    < taskdef name="pmd"  classname="com.adobe.ac.pmd.ant.FlexPmdAntTask"  classpath="${build.pmd.loc}/flex-pmd-ant-task-${flexpmd.version}.jar">
             < classpath>
                 < path refid="flexpmd.base" />
                 < pathelement  location="${build.pmd.loc}/commons-lang-2.4.jar" />
                 < pathelement  location="${build.pmd.loc}/flex-pmd-core-${flexpmd.version}.jar" />
                 < pathelement  location="${build.pmd.loc}/flex-pmd-ruleset-api-${flexpmd.version}.jar"  />
                 < pathelement  location="${build.pmd.loc}/flex-pmd-ruleset-${flexpmd.version}.jar"  />
                 < pathelement  location="${build.pmd.loc}/plexus-utils-1.0.2.jar" />
             < /classpath>
    < /taskdef>
    then generate XML  report like this :
    < pmd  sourceDirectory="${src.loc}" outputDirectory="${report.loc}"  ruleSet="${build.pmd.loc}/rules.xml"/>
    The  XML contains some file nodes :
    < file  name="/Users/user/workspace/AS3_UTILS/src/utils/align/gridAlignSpaceNumber.as">
           < violation beginline="22" endline="22" begincolumn="0"  endcolumn="27" rule="adobe.ac.pmd.rules.naming.TooShortVariable"  ruleset="All Flex Rules" package="utils.align"  class="gridAlignSpaceNumber.as" externalInfoUrl="" priority="5">This  variable name is too short (3 characters minimum, but 1 actually).  Detects when a field, local, or parameter has a very short name<  /violation>
    < /file>
    The  message is in the text node  < violation>TEXT< /violation>
    For  me, we miss an important part of the message : the portion of the "bad"  code.
    It could be very usefull if PMD can generate  something like this :
    < file  name="">
           < violation beginline="" endline="" begincolumn=""  endcolumn="" rule=""  ruleset="" package=""  class="gridAlignSpaceNumber.as" externalInfoUrl="" priority="">
            < description>TEXT< /description>
            < code><CDATA[MY CODE
    MY CODE
    MY CODE]>< /code>
        <  /violation>
    < /file>
    With this, we can  generate "full" HTML report with XSLT transform easily.
    I  understand that it modify the standard XML schema of the output.
    So,  perharps it could be an option like this :
    < pmd fullDescription="true"  sourceDirectory="${src.loc}"  outputDirectory="${report.loc}"  ruleSet="${build.pmd.loc}/rules.xml"/>
    What do you think ?
    Thanks !

  • Can i avoid needing to manually enumerate all TestCases in a TestRunner for an ant build?

    flexunit gurus,
    i've been experimenting with the FlexUnit4SampleCIProject as part of following the instructions for ant builds at http://docs.flexunit.org/index.php?title=Ant_Task
    this sample project utilizes a TestRunner.mxml file that manually enumerates every TestCase that should be run as part of the tests.  e.g. after i modified TestRunner.mxml to test my locally developed classes, a snippet looks like this:
                    var core : FlexUnitCore = new FlexUnitCore();
                    core.run(MathUtilTest, StringUtilTest);
    the ant build then invokes that TestRunner as part of the build:
            <!-- Execute TestRunner.swf as FlexUnit tests and publish reports -->
            <flexunit swf="${bin.loc}/TestRunner.swf"
                toDir="${report.loc}"
                haltonfailure="false"
                headless="false"
                verbose="true"
                localTrusted="true" />
    the associated maven build for this project does not require a TestRunner.mxml.  the following snippets from the configuration of the flexmojos plugin in the pom.xml allows for the TestCases to be run without needing to manually enumerate them ahead of time::
                   <includeTestFiles>
                      <includeTestFile>*Test.as</includeTestFile>
                   </includeTestFiles>
    Flash Builder 4 now supports a model like flexmojos - I can simply right click a project or folder and select Execute FlexUnit Tests and all the tests are run, without needing a TestRunner.mxml.  Flash Builder appears to accomplish this by dynamically generating (and then compiling and executing) 2 mxml files based on the FlexUnit tests found in the project/folder.  In Flex Builder 3 days, I had to manually maintain a TestRunner.mxml, which was error prone and cumbersome.
    my question is whether there is support in an ant build for running all *Test.as files without needing an associated TestRunner.mxml.  if so, could you post an example on how to accomplish this?  i suppose i could create a custom ant task that dynamically generates a mxml file after searching the file system for *Test.as files (similar to what Flash Builder 4 does), but since this seems like such a common need i'm hoping it is (or can be) provided as part of FlexUnit's ant tasks.
    thanks.
    -mike

    they aren't there yet, but...
    if you want to have a little fun, this code is already in our github master
    <flexunit workingDir="${bin.loc}" toDir="${report.loc}"
    haltonfailure="false" verbose="true" localTrusted="true">
       <testSource dir="${main.src.loc}" />
       <testSource dir="${test.src.loc}">
          <include name="**/*Test.as" />
       </testSource>
       <library dir="${lib.loc}" />
    </flexunit>
    documentation and being 'official' are not far off, but due to some logisitcs I can't give you a firm date just yet,
    mike

  • Environment variables not passed through to player in flexunit 4.1.0-beta3

    fyi, to get flexunit-4.1.0-beta3 FlexUnit4AntTasks invocation of flashplayer to not be rejected by the vncserver, i needed to modify the FlexUnitLauncher to pass through the environment variables to the command environment.
    the reason this is required, i think, is the use of Runtime.exec() directly in CustomPlayerCommand -- in flexunit-4.0.0, the same function was accomplished using the ant executor, which does passthrough by default.
    anyway, curious if anyone else has seen this issue, or if i'm doing something dumb.
    --- flexunit/flexunit-4.1.0-beta3/flexunit-flexunit-da29198/FlexUnit4AntTasks/src/org/flexuni t/ant/launcher/FlexUnitLauncher.java    (revision 7250)
    +++ flexunit/flexunit-4.1.0-beta3/flexunit-flexunit-da29198/FlexUnit4AntTasks/src/org/flexuni t/ant/launcher/FlexUnitLauncher.java    (revision 7251)
    @@ -79,7 +82,13 @@
           command.setSwf(swf);
           if (runHeadless())
    -         command.setEnvironment(new String[]{ "DISPLAY=:" + xvncStart.getCurrentDisplay() });
    +         Map<String, String> env = System.getenv();
    +         List<String> envArgs = new ArrayList<String>();
    +         for (Map.Entry<String, String> entry : env.entrySet()) {
    +            envArgs.add(entry.getKey() + "=" + entry.getValue());
    +         }
    +         envArgs.add("DISPLAY=:"+xvncStart.getCurrentDisplay());
    +         command.setEnvironment(envArgs.toArray(new String[0]));
              LoggingUtil.log("Setting DISPLAY=:" + xvncStart.getCurrentDisplay());

    ok. i went looking for a JIRA link somewhere around here and couldn't find it.  do you have a URL handy?
    there are a couple of other things too:
    you probably want trustDirectory.mkdirs() rather than mkdir() in TrustFile.java
    you probably want CustomPlayerCommand.setLocalTrusted() -- my player command isn't in the machine's path, but i still want to be able to touch the trust file.  So I copied the trustFile.add() stuff from FlashPlayerCommand.launch() into CustomPlayerCommand.launch().  probably a better solution would be refactoring CustomPlayerCommand to be more like FlashPlayerCommand.
    anyway, if you want patches, tell me where to put them and i'll post some.

  • AIR-LAP 1231G-A-K9

       I have a couple of questions: I have a 161 AP,s most of which are AIR-LAP 1231G-A-K9 two 4400 WLC.
    Some of these APs are using  AIR-ANT 1728 (2.4 GHz omidirectional 5.2 dBi)  and Mobile Mark OD9-240 (2-GHz omnidirectional  9 dBi) on the same access points. Some of my AP are PoE and some are using a power supply (at the AP) some are using both. Power level is set at 2 a radios are not enabled just the bg radios. I'm having issues: I need to tweak the APs (Power settings & Channel settings) so my clients (LXE VX6) can refresh faster.
    Any suggestions?
    PS I did'nt set this up. It was handed to me.              

    All of the enabled APs have thier A radios disabled.
    1231 don't have 802.11a radios.  You are using two type of antennaes (5 dBi and 9 dBi) in the SAME UNIT.
    The only way to determine if you have proper signal is to walk around with a laptop and sniff out the signal.  If you have signal strength of about 65 to 75 dBi then this is good.  If your signal being received by the laptop is higher than 80 dBi then this is one of your problems.
    Please check if all the data rates for 802.11b and 802.11g are enabled.
    You may want to propose to management to upgrade your WAPs as they are old.  If they want something cheap (supports only 802.11 a/b/g) and with external antennas then 1240 is your option.  If you want internal antenna 1130 is still in the market.
    If management want internal antenna and support 802.11 a/b/g/n then the cheapest model is the 1040.  The 1260 will support 802.11 a/b/g/n and requires antennas.

  • FU4CIListener build.xml not setting properties?

    I am following the Ant Task Setup.  I have flex sdk 3.6.0.X, apache-ant 1.8.2 and the flexunit source 4.1.0.
    When I run > ant -v clean package
    function(){return A.apply(null,[this].concat($A(arguments)))}
    Apache Ant(TM) version 1.8.2 compiled on December 20 2010
    Trying the default build file: build.xml
    Buildfile: C:\projects\FlexUnit4CIListener\build.xml
    Detected Java version: 1.7 in: C:\Program Files\Java\jdk1.7.0\jre
    Detected OS: Windows XP
    parsing buildfile C:\projects\FlexUnit4CIListener\build.xml with URI = file:/C:/projects/FlexUnit4CIListener/build.xml
    Project base dir set to: C:\projects\FlexUnit4CIListener
    parsing buildfile jar:file:/C:/apacheAnt/lib/ant.jar!/org/apache/tools/ant/antlib.xml with URI = jar:file:/C:/apacheAnt/lib/ant.jar!/org/apache/tools/ant/antlib.xml from a zip file
    Importing file C:\projects\utils.xml from C:\projects\FlexUnit4CIListener\build.xml
    Overriding previous definition of reference to ant.projectHelper
    parsing buildfile C:\projects\utils.xml with URI = file:/C:/projects/utils.xml
    [macrodef] creating macro  gpg
    [macrodef] creating macro  sonatype-bundle
    Overriding previous definition of reference to ant.projectHelper
    [property] Loading Environment env.
    Property "build.version" has not been set
    Property "build.number" has not been set
    Property "build.sdk" has not been set
    Build sequence for target(s) `clean' is [clean]
    Complete build sequence is [clean, init, compile, report, package, deploy, ]
    clean:
       [delete] Deleting directory C:\projects\FlexUnit4CIListener\target
       [delete] Deleting directory C:\projects\FlexUnit4CIListener\target\bin
       [delete] Deleting directory C:\projects\FlexUnit4CIListener\target\docs
       [delete] Deleting directory C:\projects\FlexUnit4CIListener\target\sonatype
       [delete] Deleting directory C:\projects\FlexUnit4CIListener\target
       [delete] Deleting C:\projects\FlexUnit4CIListener\libs\flexunit-4.1.0-x-as3_y.y.y.y.swc
    Build sequence for target(s) `package' is [init, compile, report, package]
    Complete build sequence is [init, compile, report, package, clean, deploy, ]
    init:
        [mkdir] Skipping C:\projects\FlexUnit4CIListener\libs because it already exists.
        [mkdir] Created dir: C:\projects\FlexUnit4CIListener\target
        [mkdir] Created dir: C:\projects\FlexUnit4CIListener\target\sonatype
        [mkdir] Created dir: C:\projects\FlexUnit4CIListener\target\bin
        [mkdir] Created dir: C:\projects\FlexUnit4CIListener\target\docs
         [copy] Copying 1 file to C:\projects\FlexUnit4CIListener\libs
         [copy] Copying C:\projects\FlexUnit4\target\flexunit-4.1.0-x-as3_y.y.y.y.swc to C:\projects\FlexUnit4CIListener\libs\flexunit-4.1.0-x-as3_y.y.y.y.swc
    compile:
        [compc] Loading configuration file C:\flexunit\frameworks\flex-config.xml
        [compc] Adobe Compc (Flex Component Compiler)
        [compc] Version 3.6.0 build 16995
        [compc] Copyright (c) 2004-2007 Adobe Systems, Inc. All rights reserved.
        [compc]
        [compc] command line: Error: configuration variable 'output' value contains unknown token 'build.version'
        [compc]
        [compc] Use 'compc -help' for information about using the command line.
    BUILD FAILED
    C:\projects\FlexUnit4CIListener\build.xml:50: compc task failed
            at flex.ant.FlexTask.executeInProcess(FlexTask.java:299)
            at flex.ant.FlexTask.execute(FlexTask.java:225)
            at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
            at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
            at java.lang.reflect.Method.invoke(Method.java:601)
            at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
            at org.apache.tools.ant.Task.perform(Task.java:348)
            at org.apache.tools.ant.Target.execute(Target.java:390)
            at org.apache.tools.ant.Target.performTasks(Target.java:411)
            at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1399)
            at org.apache.tools.ant.Project.executeTarget(Project.java:1368)
            at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
            at org.apache.tools.ant.Project.executeTargets(Project.java:1251)
            at org.apache.tools.ant.Main.runBuild(Main.java:809)
            at org.apache.tools.ant.Main.startAnt(Main.java:217)
            at org.apache.tools.ant.launch.Launcher.run(Launcher.java:280)
            at org.apache.tools.ant.launch.Launcher.main(Launcher.java:109)
    Total time: 1 second
    build.version, build.number & build.sdk are properties that are not being set.  I would assume that they should be set internally somehow.  However, if I manually set them via -D switches (with arbitrary values) I get the following:
    >ant -v clean package -Dbuild.version=1.2.3.4 -Dbuild.number=666 -Dbuild.sdk=4.1
    function(){return A.apply(null,[this].concat($A(arguments)))}
    Apache Ant(TM) version 1.8.2 compiled on December 20 2010
    Trying the default build file: build.xml
    Buildfile: C:\projects\FlexUnit4CIListener\build.xml
    Detected Java version: 1.7 in: C:\Program Files\Java\jdk1.7.0\jre
    Detected OS: Windows XP
    parsing buildfile C:\projects\FlexUnit4CIListener\build.xml with URI = file:/C:/projects/FlexUnit4CIListener/build.xml
    Project base dir set to: C:\projects\FlexUnit4CIListener
    parsing buildfile jar:file:/C:/apacheAnt/lib/ant.jar!/org/apache/tools/ant/antlib.xml with URI = jar:file:/C:/apacheAnt/lib/ant.jar!/org/apache/tools/ant/antlib.xml from a zip file
    Importing file C:\projects\utils.xml from C:\projects\FlexUnit4CIListener\build.xml
    Overriding previous definition of reference to ant.projectHelper
    parsing buildfile C:\projects\utils.xml with URI = file:/C:/projects/utils.xml
    [macrodef] creating macro  gpg
    [macrodef] creating macro  sonatype-bundle
    Overriding previous definition of reference to ant.projectHelper
    [property] Loading Environment env.
    Build sequence for target(s) `clean' is [clean]
    Complete build sequence is [clean, init, compile, report, package, deploy, ]
    clean:
       [delete] Deleting directory C:\projects\FlexUnit4CIListener\target
       [delete] Deleting directory C:\projects\FlexUnit4CIListener\target\bin
       [delete] Deleting directory C:\projects\FlexUnit4CIListener\target\docs
       [delete] Deleting directory C:\projects\FlexUnit4CIListener\target\sonatype
       [delete] Deleting directory C:\projects\FlexUnit4CIListener\target
       [delete] Deleting C:\projects\FlexUnit4CIListener\libs\flexunit-4.1.0-x-as3_y.y.y.y.swc
    Build sequence for target(s) `package' is [init, compile, report, package]
    Complete build sequence is [init, compile, report, package, clean, deploy, ]
    init:
        [mkdir] Skipping C:\projects\FlexUnit4CIListener\libs because it already exists.
        [mkdir] Created dir: C:\projects\FlexUnit4CIListener\target
        [mkdir] Created dir: C:\projects\FlexUnit4CIListener\target\sonatype
        [mkdir] Created dir: C:\projects\FlexUnit4CIListener\target\bin
        [mkdir] Created dir: C:\projects\FlexUnit4CIListener\target\docs
         [copy] Copying 1 file to C:\projects\FlexUnit4CIListener\libs
         [copy] Copying C:\projects\FlexUnit4\target\flexunit-4.1.0-x-as3_y.y.y.y.swc to C:\projects\FlexUnit4CIListener\libs\flexunit-4.1.0-x-as3_y.y.y.y.swc
    compile:
        [compc] Loading configuration file C:\flexunit\frameworks\flex-config.xml
        [compc] C:\projects\FlexUnit4CIListener\target\bin\flexunit-cilistener-1.2.3.4-666-4.1.swc (11773 bytes)
    report:
    Skipped because property 'build.report' not set.
    package:
         [copy] Copying 1 file to C:\projects\FlexUnit4CIListener\target
         [copy] Copying C:\projects\FlexUnit4CIListener\target\bin\flexunit-cilistener-1.2.3.4-666-4.1.swc to C:\projects\FlexUnit4CIListener\target\flexunit-cilistener-1.2.3.4-666-4.1.swc
    BUILD SUCCESSFUL
    Total time: 4 seconds
    I can see where the previous 3 properties are being used in the swc output file name, but now there is a build.report property that is not being set.  How do I know which properties need to be set, and what to set them to?

    I was using the 4.5.1 flex SDK but there seemed to be other issues so I just used the link directly from the Ant Task Setup page (instead of using the newest SDK).  Upon following your instructions to ant build from the root directory, everything seemed to work correctly with a few exceptions.  Below is the last part of the output from the build.
    function(){return A.apply(null,[this].concat($A(arguments)))}
    test:
    Detected Java version: 1.7 in: C:\Program Files\Java\jdk1.7.0\jre
    Detected OS: Windows XP
    Project base dir set to: C:\projects\FlexUnit4Test
          [ant] calling target(s) [test] in build file C:\projects\FlexUnit4Test\build.xml
    parsing buildfile C:\projects\FlexUnit4Test\build.xml with URI = file:/C:/projects/FlexUnit4Test/build.xml
    Project base dir set to: C:\projects\FlexUnit4Test
    [property] Loading Environment env.
    Override ignored for property "FLEX_HOME"
    Property "env.FLEX_COVER_VIEWER" has not been set
    [macrodef] creating macro  compile-runner
    [macrodef] creating macro  execute-tests
    [macrodef] creating macro  execute-tests-using-flexcover
    [macrodef] creating macro  generate-html-report
          [ant] Entering C:\projects\FlexUnit4Test\build.xml...
    Build sequence for target(s) `test' is [init, test-only, test-and-instrument, test]
    Complete build sequence is [init, test-only, test-and-instrument, test, clean, ]
    init:
        [mkdir] Created dir: C:\projects\FlexUnit4Test\target
        [mkdir] Created dir: C:\projects\FlexUnit4Test\target\bin
        [mkdir] Created dir: C:\projects\FlexUnit4Test\target\report\xunit\flex
        [mkdir] Created dir: C:\projects\FlexUnit4Test\target\report\xunit\as3
        [mkdir] Created dir: C:\projects\FlexUnit4Test\target\report\flexcover
         [copy] Copying 5 files to C:\projects\FlexUnit4Test\libs
         [copy] Copying C:\projects\FlexUnit4CIListener\target\flexunit-cilistener-4.1.0-x-y.y.y.y.swc to C:\projects\FlexUnit4Test\libs\flexunit-cilistener-4.1.0-x-y.y.y.y.swc
         [copy] Copying C:\projects\FlexUnit4FluintExtensions\target\fluint-extensions-4.1.0-x-y.y.y.y.swc to C:\projects\FlexUnit4Test\libs\fluint-extensions-4.1.0-x-y.y.y.y.swc
         [copy] Copying C:\projects\FlexUnit4\target\flexunit-4.1.0-x-as3_y.y.y.y.swc to C:\projects\FlexUnit4Test\libs\flexunit-4.1.0-x-as3_y.y.y.y.swc
         [copy] Copying C:\projects\FlexUnit4\target\flexunit-4.1.0-x-flex_y.y.y.y.swc to C:\projects\FlexUnit4Test\libs\flexunit-4.1.0-x-flex_y.y.y.y.swc
         [copy] Copying C:\projects\FlexUnit4FlexCoverListener\target\flexunit-flexcoverlistener-4.1.0-x-y.y.y.y. swc to C:\projects\FlexUnit4Test\libs\flexunit-flexcoverlistener-4.1.0-x-y.y.y.y.swc
         [copy] Copying 1 file to C:\projects\FlexUnit4Test\libs\build
         [copy] Copying C:\projects\FlexUnit4AntTasks\target\flexUnitTasks-4.1.0-x.jar to C:\projects\FlexUnit4Test\libs\build\flexUnitTasks-4.1.0-x.jar
    test-only:
         [echo] Testing FlexUnit Flex build...
        [mxmlc] Loading configuration file C:\flexunit\frameworks\flex-config.xml
        [mxmlc] C:\projects\FlexUnit4Test\target\bin\TestRunner-flex.swf (924564 bytes)
    [flexunit] Validating task attributes ...
    [flexunit] Generating default values ...
    [flexunit] Using default working dir [C:\projects\FlexUnit4Test]
    [flexunit] Using the following settings for the test run:
    [flexunit]  FLEX_HOME: [C:\flexunit]
    [flexunit]  haltonfailure: [false]
    [flexunit]  headless: [false]
    [flexunit]  display: [99]
    [flexunit]  localTrusted: [true]
    [flexunit]  player: [flash]
    [flexunit]  port: [1024]
    [flexunit]  swf: [C:\projects\FlexUnit4Test\target\bin\TestRunner-flex.swf]
    [flexunit]  timeout: [60000ms]
    [flexunit]  toDir: [C:\projects\FlexUnit4Test\target\report\xunit\flex]
    [flexunit] Setting up server process ...
    [flexunit] Starting server ...
    [flexunit] Entry [C:\projects\FlexUnit4Test\target\bin] already available in local trust file at [C:\Documents and Settings\Administrator\Application Data\Macromedia\Flash Player\#Security\FlashPlayerTrust\flexUnit.cfg].
    [flexunit] Executing 'rundll32' with arguments:
    [flexunit] 'url.dll,FileProtocolHandler'
    [flexunit] 'C:\projects\FlexUnit4Test\target\bin\TestRunner-flex.swf'
    [flexunit]
    [flexunit] The ' characters around the executable and arguments are
    [flexunit] not part of the command.
    [flexunit]
    [flexunit] Opening server socket on port [1024].
    [flexunit] Waiting for client connection ...
    [flexunit]
    [flexunit] Stopping server ...
    [flexunit] End of test data reached, sending acknowledgement to player ...
    [flexunit] Closing client connection ...
    [flexunit] Closing server on port [1024] ...
          [ant] Exiting C:\projects\FlexUnit4Test\build.xml.
    After this part of the log I get the following:
    function(){return A.apply(null,[this].concat($A(arguments)))}
    BUILD FAILED
    C:\projects\build.xml:103: The following error occurred while executing this line:
    C:\projects\FlexUnit4Test\build.xml:180: The following error occurred while executing this line:
    C:\projects\FlexUnit4Test\build.xml:62: java.util.concurrent.ExecutionException: Socket timeout waiting for flexunit report
            at java.util.concurrent.FutureTask$Sync.innerGet(FutureTask.java:252)
            at java.util.concurrent.FutureTask.get(FutureTask.java:111)
            at org.flexunit.ant.tasks.TestRun.run(Unknown Source)
            at org.flexunit.ant.tasks.FlexUnitTask.execute(Unknown Source)
            at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
            at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
            at java.lang.reflect.Method.invoke(Method.java:601)
            at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
            at org.apache.tools.ant.Task.perform(Task.java:348)
            at org.apache.tools.ant.taskdefs.Sequential.execute(Sequential.java:68)
            at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
            at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
            at java.lang.reflect.Method.invoke(Method.java:601)
            at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
            at org.apache.tools.ant.Task.perform(Task.java:348)
            at org.apache.tools.ant.taskdefs.MacroInstance.execute(MacroInstance.java:398)
            at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
            at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
            at java.lang.reflect.Method.invoke(Method.java:601)
            at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
            at org.apache.tools.ant.Task.perform(Task.java:348)
            at org.apache.tools.ant.Target.execute(Target.java:390)
            at org.apache.tools.ant.Target.performTasks(Target.java:411)
            at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1399)
            at org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(SingleCheckExecutor.java:3 8)
            at org.apache.tools.ant.Project.executeTargets(Project.java:1251)
            at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:442)
            at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:291)
            at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
            at java.lang.reflect.Method.invoke(Method.java:601)
            at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
            at org.apache.tools.ant.Task.perform(Task.java:348)
            at org.apache.tools.ant.Target.execute(Target.java:390)
            at org.apache.tools.ant.Target.performTasks(Target.java:411)
            at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1399)
            at org.apache.tools.ant.Project.executeTarget(Project.java:1368)
            at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
            at org.apache.tools.ant.Project.executeTargets(Project.java:1251)
            at org.apache.tools.ant.Main.runBuild(Main.java:809)
            at org.apache.tools.ant.Main.startAnt(Main.java:217)
            at org.apache.tools.ant.launch.Launcher.run(Launcher.java:280)
            at org.apache.tools.ant.launch.Launcher.main(Launcher.java:109)
    Caused by: Socket timeout waiting for flexunit report
            at org.flexunit.ant.FlexUnitSocketServer.start(Unknown Source)
            at org.flexunit.ant.FlexUnitSocketThread.call(Unknown Source)
            at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334)
            at java.util.concurrent.FutureTask.run(FutureTask.java:166)
            at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
            at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
            at java.lang.Thread.run(Thread.java:722)
    Caused by: java.net.SocketTimeoutException: Accept timed out
            at java.net.TwoStacksPlainSocketImpl.socketAccept(Native Method)
            at java.net.AbstractPlainSocketImpl.accept(AbstractPlainSocketImpl.java:396)
            at java.net.PlainSocketImpl.accept(PlainSocketImpl.java:183)
            at java.net.ServerSocket.implAccept(ServerSocket.java:522)
            at java.net.ServerSocket.accept(ServerSocket.java:490)
            at org.flexunit.ant.FlexUnitSocketServer.openClientSocket(Unknown Source)
            ... 7 more
    Total time: 1 minute 38 seconds
    So everything seems to be building correctly now, but not executing correctly.  Also, there are still a number of properties that are not being set:
    function(){return A.apply(null,[this].concat($A(arguments)))}
    report:
    Skipped because property 'build.report' not set.
    instrument-compile:
    Skipped because property 'build.instrument' not set.
    package-instrument:
    Skipped because property 'build.instrument' not set.
    pmdReport:
    Skipped because property 'build.pmd' not set.
    Where should these values be set and what are appropriate values?  What could be causing the socket timeout and what exactly is it waiting for or attempting to accomplish with the sockets?
    The end goal is to be able to use the flex SDK, flexunit and ANT on a linux server to automate my build/test process.  I am currently just trying to get ANT to work with the flex SDK and flexunit on a windows XP box so I can see what the output should be and how the whole system works before trying to inject it into my CI system.

  • Error parsing report

    Hi all,
    I'm having trouble getting the Ant task working in Linux.   The swf runs, but there seems to be an issue communicating back the test results.  I pasted a full dump of the ant output below.  I've tried it in both Fedora 8 and OpenSUSE 11.2, and with both the FlexUnit4SampleCIProject and my own project.   I also tried the updated .jar and .swc mentioned in this post.  I'm using Ant directly without Hudson or anything.
    I'm also having a hard time running headlessly, but I'm assuming that's a separate issue.
    Any help would be greatly appreciated.
    - Shane
    shane@linux-idnf:~/Download/flexunit-flexunit-91fcfdd/FlexUnit4SampleCIProject> ant clean package
    Unable to locate tools.jar. Expected to find it in /usr/lib/jvm32/jre1.6.0_18/lib/tools.jar
    Buildfile: build.xml
    clean:
       [delete] Deleting directory /home/shane/Download/flexunit-flexunit-91fcfdd/FlexUnit4SampleCIProject/target
    init:
        [mkdir] Created dir: /home/shane/Download/flexunit-flexunit-91fcfdd/FlexUnit4SampleCIProject/target
        [mkdir] Created dir: /home/shane/Download/flexunit-flexunit-91fcfdd/FlexUnit4SampleCIProject/target/bin
        [mkdir] Created dir: /home/shane/Download/flexunit-flexunit-91fcfdd/FlexUnit4SampleCIProject/target/report
        [mkdir] Created dir: /home/shane/Download/flexunit-flexunit-91fcfdd/FlexUnit4SampleCIProject/target/dist
    compile:
        [mxmlc] Loading configuration file /usr/lib/flex_sdk/frameworks/flex-config.xml
        [mxmlc] /home/shane/Download/flexunit-flexunit-91fcfdd/FlexUnit4SampleCIProject/target/bin/Main.s wf (326989 bytes)
    test:
        [mxmlc] Loading configuration file /usr/lib/flex_sdk/frameworks/flex-config.xml
        [mxmlc] /home/shane/Download/flexunit-flexunit-91fcfdd/FlexUnit4SampleCIProject/target/bin/TestRu nner.swf (852432 bytes)
    [flexunit] Validating task attributes ...
    [flexunit] Generating default values ...
    [flexunit] Using the following settings:
    [flexunit] haltonfailure: [false]
    [flexunit] headless: [false]
    [flexunit] display: [99]
    [flexunit] localTrusted: [true]
    [flexunit] player: [flash]
    [flexunit] port: [1024]
    [flexunit] swf: [/home/shane/Download/flexunit-flexunit-91fcfdd/FlexUnit4SampleCIProject/target/bin/TestR unner.swf]
    [flexunit] timeout: [60000ms]
    [flexunit] toDir: [/home/shane/Download/flexunit-flexunit-91fcfdd/FlexUnit4SampleCIProject/target/report]
    [flexunit] verbose: [true]
    [flexunit] Setting up server process ...
    [flexunit] Starting server ...
    [flexunit] OS: [Linux]
    [flexunit] Opening server socket on port [1024].
    [flexunit] Waiting for client connection ...
    [flexunit] Launching player:
    [flexunit] Executing 'gflashplayer' with arguments:
    [flexunit] '/home/shane/Download/flexunit-flexunit-91fcfdd/FlexUnit4SampleCIProject/target/bin/TestR unner.swf'
    [flexunit]
    [flexunit] The ' characters around the executable and arguments are
    [flexunit] not part of the command.
    [flexunit]
    [flexunit] Client connected.
    [flexunit] Setting inbound buffer size to [262144] bytes.
    [flexunit] Receiving data ...
    [flexunit] Sending acknowledgement to player to start sending test data ...
    [flexunit]
    [flexunit] <testcase classname="org.flexunit.demo::EchoPanelTest" name="testEventWasNotDispatchedWithoutClick" time="0" status="success" />
    [flexunit]
    [flexunit] Stopping server ...
    [flexunit] End of test data reached, sending acknowledgement to player ...
    [flexunit] Closing client connection ...
    [flexunit] Closing server on port [1024] ...
    BUILD FAILED
    java.util.concurrent.ExecutionException: Error parsing report.
    at java.util.concurrent.FutureTask$Sync.innerGet(Unknown Source)
    at java.util.concurrent.FutureTask.get(Unknown Source)
    at org.flexunit.ant.tasks.FlexUnitTask.execute(Unknown Source)
    at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
    at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
    at org.apache.tools.ant.Task.perform(Task.java:348)
    at org.apache.tools.ant.Target.execute(Target.java:357)
    at org.apache.tools.ant.Target.performTasks(Target.java:385)
    at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
    at org.apache.tools.ant.Project.executeTarget(Project.java:1306)
    at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
    at org.apache.tools.ant.Project.executeTargets(Project.java:1189)
    at org.apache.tools.ant.Main.runBuild(Main.java:758)
    at org.apache.tools.ant.Main.startAnt(Main.java:217)
    at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
    at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)
    Caused by: Error parsing report.
    at org.flexunit.ant.FlexUnitSocketThread.parseReport(Unknown Source)
    at org.flexunit.ant.FlexUnitSocketThread.processTestReport(Unknown Source)
    at org.flexunit.ant.FlexUnitSocketThread.parseInboundMessages(Unknown Source)
    at org.flexunit.ant.FlexUnitSocketThread.call(Unknown Source)
    at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
    at java.util.concurrent.FutureTask.run(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
    Caused by: org.dom4j.DocumentException: org.dom4j.DocumentFactory cannot be cast to org.dom4j.DocumentFactory Nested exception: org.dom4j.DocumentFactory cannot be cast to org.dom4j.DocumentFactory
    at org.dom4j.io.SAXReader.read(SAXReader.java:484)
    at org.dom4j.DocumentHelper.parseText(DocumentHelper.java:278)
    ... 9 more
    Total time: 15 seconds

    @legrosb Only one line shows up in flashlog.txt:
    <testcase classname="org.flexunit.demo::EchoPanelTest" name="testEventWasNotDispatchedWithoutClick" time="0" status="success" />
    I'm sure I made some changes to the sample project yesterday, so I set up a fresh copy just now (which didn't help).
    I do have an Ubuntu box handy if you think it'd be worth a try there.  Headless on the Fedora box is the ultimate goal, though.
    I'm using the flash player 10 standalone debugger (I tried the standalone standard player, too).  I do have all the dependencies listed for Flash Player 10 on the page you linked.
    When I try running headlessly, the ant task hangs for a while and then quits with the message "Socket timeout waiting for flexunit report" (Ant dump below).  As far as I can tell, the flash player is never actually being launched.  No flashlog.txt is generated, and I don't see gflashplayer show up in "top".  I tried attaching vncviewer to :99, but it goes up and down so quickly it's hard to attach and see what's going on.
    I'm not seeing any gtk errors in the Ant output. Is there a log file I should be looking at?
    Interesting.  If start a build of the sample project, then open up a separate terminal, set DISPLAY=:99, and run gflashplayer within the second or so that the vnc server is actually running, I get:
    shane@linux-idnf:~/Download/flexunit-clean/FlexUnit4SampleCIProject> gflashplayer
    WARNING: environment variable G_FILENAME_ENCODING set and it is not UTF-8
    Xlib:  extension "RANDR" missing on display ":99.0".
    gflashplayer: Fatal IO error 11 (Resource temporarily unavailable) on X server :99.0.
    Segmentation fault
    The Fedora box is a headless server, but I installed X Windows and vnc-server on it for this.  The OpenSUSE box is a normal desktop machine.
    "Were you using Xvnc, xvfb, or the built in support for the Ant task?"
    I'm not sure.  I set headless="true" in the <flexunit /> task, which causes it to call vncserver (which calls Xvnc, I think?).
    Aha.  I found a workaround.  I set headless="false" in the build.xml, and before calling ant, I ran:
    $ vncserver :150
    $ DISPLAY=:150
    And everything works beautifully (until it gets to the other error, that is).
    Another issue I ran into that others might want to watch out for is if your vnc server is using twm, twm might be configured to wait for the user specify the window position with the mouse, which means flash will never launch on a headless server.  The fix is to add the line "RandomPlacement" to your ~/.twmrc, or specify a different window manager in ~/.vnc/xstartup.
    - Shane
    ####Broken headless Ant dump#####
    shane@linux-idnf:~/Download/flexunit-clean/FlexUnit4SampleCIProject> ant clean package
    Unable to locate tools.jar. Expected to find it in /usr/lib/jvm32/jre1.6.0_18/lib/tools.jar
    Buildfile: build.xml
    clean:
      [delete] Deleting directory /home/shane/Download/flexunit-clean/FlexUnit4SampleCIProject/target
    init:
        [mkdir] Created dir: /home/shane/Download/flexunit-clean/FlexUnit4SampleCIProject/target
        [mkdir] Created dir: /home/shane/Download/flexunit-clean/FlexUnit4SampleCIProject/target/bin
        [mkdir] Created dir: /home/shane/Download/flexunit-clean/FlexUnit4SampleCIProject/target/report
        [mkdir] Created dir: /home/shane/Download/flexunit-clean/FlexUnit4SampleCIProject/target/dist
    compile:
        [mxmlc] Loading configuration file /usr/lib/flex_sdk/frameworks/flex-config.xml
        [mxmlc] /home/shane/Download/flexunit-clean/FlexUnit4SampleCIProject/target/bin/Main.swf (326985 bytes)
    test:
        [mxmlc] Loading configuration file /usr/lib/flex_sdk/frameworks/flex-config.xml
        [mxmlc] /home/shane/Download/flexunit-clean/FlexUnit4SampleCIProject/target/bin/TestRunner.swf (852432 bytes)
    [flexunit] Validating task attributes ...
    [flexunit] OS: [Linux]
    [flexunit] Generating default values ...
    [flexunit] Using the following settings:
    [flexunit] haltonfailure: [false]
    [flexunit] headless: [true]
    [flexunit] display: [99]
    [flexunit] localTrusted: [true]
    [flexunit] player: [flash]
    [flexunit] port: [1024]
    [flexunit] swf: [/home/shane/Download/flexunit-clean/FlexUnit4SampleCIProject/target/bin/TestRunner.swf]
    [flexunit] timeout: [60000ms]
    [flexunit] toDir: [/home/shane/Download/flexunit-clean/FlexUnit4SampleCIProject/target/report]
    [flexunit] verbose: [true]
    [flexunit] Setting up server process ...
    [flexunit] Starting server ...
    [flexunit] Opening server socket on port [1024].
    [flexunit] Waiting for client connection ...
    [flexunit] OS: [Linux]
    [flexunit] Starting xvnc
    [flexunit] Attempting start on :99 ...
    [flexunit] Launching player:
    [flexunit] Executing 'gflashplayer' with arguments:
    [flexunit] '/home/shane/Download/flexunit-clean/FlexUnit4SampleCIProject/target/bin/TestRunner.swf'
    [flexunit]
    [flexunit] The ' characters around the executable and arguments are
    [flexunit] not part of the command.
    [flexunit]
    [flexunit] Terminating xvnc on :99
    <<<Hangs here for about a minute>>>
    [flexunit]
    [flexunit] Stopping server ...
    [flexunit] End of test data reached, sending acknowledgement to player ...
    [flexunit] Closing client connection ...
    [flexunit] Closing server on port [1024] ...
    BUILD FAILED
    java.util.concurrent.ExecutionException: Socket timeout waiting for flexunit report
    at java.util.concurrent.FutureTask$Sync.innerGet(Unknown Source)
    at java.util.concurrent.FutureTask.get(Unknown Source)
    at org.flexunit.ant.tasks.FlexUnitTask.execute(Unknown Source)
    at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
    at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
    at org.apache.tools.ant.Task.perform(Task.java:348)
    at org.apache.tools.ant.Target.execute(Target.java:357)
    at org.apache.tools.ant.Target.performTasks(Target.java:385)
    at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
    at org.apache.tools.ant.Project.executeTarget(Project.java:1306)
    at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
    at org.apache.tools.ant.Project.executeTargets(Project.java:1189)
    at org.apache.tools.ant.Main.runBuild(Main.java:758)
    at org.apache.tools.ant.Main.startAnt(Main.java:217)
    at org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
    at org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)
    Caused by: Socket timeout waiting for flexunit report
    at org.flexunit.ant.FlexUnitSocketServer.start(Unknown Source)
    at org.flexunit.ant.FlexUnitSocketThread.call(Unknown Source)
    at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
    at java.util.concurrent.FutureTask.run(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
    Caused by: java.net.SocketTimeoutException: Accept timed out
    at java.net.PlainSocketImpl.socketAccept(Native Method)
    at java.net.PlainSocketImpl.accept(Unknown Source)
    at java.net.ServerSocket.implAccept(Unknown Source)
    at java.net.ServerSocket.accept(Unknown Source)
    at org.flexunit.ant.FlexUnitSocketServer.openClientSocket(Unknown Source)
    ... 7 more
    Total time: 1 minute 13 seconds

  • Antenna type in WCS / WLC

    Hello, I am still somewhat new to the wireless side and I saw something today while trying to troubleshoot a wireless issue we were having that I have not heard or read about from my CCNA Wireless studies. I noticed that the antenna types our WCS is showing attached to my APs are wrong.
    My question is, do the APs / WCS / WLC know what type of antenna is connected to the APs automatically or is this a manual process that someone should assign them? The second question is, if it is a manual process (which I suspect it will be) can I change it without disrupting current connections or should I wait until a maintenance window to do this?
    We have 3502e AP with AIR-ANT-1728 and AIR-ANT-5150V-R antennas attached to them, but my WCS says they have the rubber duckies on them. Any insight would be greatly appreciated.
    Thank you in advance for any help you can provide!                    

    There is no way the WLC even knows what antennas you have. If your using antennas besides the rubber ducks then you need to define that on WCS. If you have Cisco antennas, there is a drop list of the antennas. You also have to make sure of the antenna orientation. This is all defined in the WCS user guide.
    Note
    If you have a ceiling-mounted AP with an integrated omni-directional antenna, the antenna orientation does not really need to be set in WCS. However, if you mount that same AP on the wall, you must set the antenna orientation to 90 degrees.
    Sent from Cisco Technical Support iPhone App

  • Aironet 1260 and external Antenna

    I know you can put a minimum of 3 AIR-ANT-2422 antenna on the 1261 AP but my question is, can you mix and match antenna?
    Currently there is an AIR-ANT-24120 used on an older 1200 model. Upgrading to a 1261. The 24120 is 12db and 2422 is 2.4db.
    Environment is Manufacturing floor with 30' ceilings, worried about coverage. Can the 24120 work on the 1261 or am I stuck with the 2422s?
    Thanks

    You can't mix-and-match these two.  AIR-ANT-24120 is a 12 dBi antenna.  The 1260 will not support anything higher than 6 dBi because this model simply doesn't have enough power to do so.
    The 1260, 3500e and 3600e doesn't have enough power because in the past people kept complaining that the 1250 needed 20.0w PoE power.  Now the the 1250 doesn't have any limitation about the maximum (maybe it does but I haven't seen or heard of it) gain support.  So Cisco cranked down the power requirement of the new WAPs and balanced it to the antenna gain.

  • Socket timeout on Mac

    Hello,
    I am trying to run the flexunit ANT task on a Mac but keep getting the following error.
    [flexunit] Stopping server ...
    [flexunit] End of test data reached, sending acknowledgement to player ...
    [flexunit] Closing client connection ...
    [flexunit] Closing server on port [1024] ...
    "Socket timeout waiting for flexunit report"
    I see the test runner launch in Flash Player but then nothing else happens after that.  I'm assuming FlexUnit isn't able to communicate with flash player but at this point i am not sure how to remedy the problem.
    Does anyone have any suggestions on how to get flexunit and ANT working on a Mac?
    Thanks.

    Thanks for the help so far.  I am using the RC1 SWCs.  I've also tried different ports but that didn't help either.  The flexUnit.cfg file is getting created.
    This is what my flexunit task looks like (defined in a macro)...
                <flexunit swf="@{bin.dir}/@{mxml.name}.swf" toDir="@{report.dir}"
                    player="flash"
                    headless="true"
                    haltonfailure="false"
                    verbose="true"
                    localTrusted="true" />
    And here is my build output...
    [flexunit] Using the following settings:
    [flexunit]     haltonfailure: [false]
    [flexunit]     headless: [true]
    [flexunit]     localTrusted: [true]
    [flexunit]     player: [flash]
    [flexunit]     port: [1024]
    [flexunit]     snapshot: [false]
    [flexunit]     snapshotFile: [---/controller/controller-shell/report/snapshot.jpg]
    [flexunit]     swf: [---/controller/controller-shell/bin/ControllerTestRunner.swf]
    [flexunit]     timeout: [60000ms]
    [flexunit]     toDir: [---/controller/controller-shell/report]
    [flexunit]     verbose: [true]
    [flexunit]     xcommand: [xvfb]
    [flexunit] Setting up server process ...
    [flexunit] Starting server ...
    [flexunit] OS: [Mac OSX]
    [flexunit] Opening server socket on port [1024].
    [flexunit] Waiting for client connection ...
    [flexunit] Launching player:
    [flexunit] Executing 'open' with arguments:
    [flexunit] '---/controller/controller-shell/bin/ControllerTestRunner.swf'
    [flexunit] The ' characters around the executable and arguments are
    [flexunit] not part of the command.
    [flexunit] Created local trust file at [/Users/arumsey/Library/Preferences/Macromedia/Flash Player/#Security/FlashPlayerTrust/flexUnit.cfg]
    [flexunit] Stopping server ...
    [flexunit] End of test data reached, sending acknowledgement to player ...
    [flexunit] Closing client connection ...
    [flexunit] Closing server on port [1024] ...
    BUILD FAILED
    ---/controller/build/macros.xml:64: java.util.concurrent.ExecutionException: Socket timeout waiting for flexunit report

  • Cisco 1250 dipole antenna spacing

    When using dipole antennas such as AIR-ANT 4941 with the 2.4 Ghz 1250 AP, must the antennas be spaced EXACTLY as far apart as the antenna connectors on the AP, or can the dipoles be spread further out, say to 4" spacing
    thank you
    Scott

    Let's talk a bit about Cisco diversity..
    When a conventional Access Point such as an AP-1240 is in operation, it starts off favoring the right (primary) antenna, this is the antenna the Access Point typically uses to communicate to the 802.11a or b/g client. When the client starts to get out of range and retries result, the Access Point then samples the secondary antenna and if the signal is better it will use same. A client out in the very fringe area could benefit by as much as a 3 dB gain in certain null or problematic fringe areas.
    Lets talk about how the 1250 Diversity works...
    With an 802.11n Access Point such as the AP-1250 (unlike the older conventional Access Point) each antenna has a dedicated radio so there is no delay when it comes to switching antennas (to determine which one is the best). An added benefit when the signals are OFDM (as is with 802.11g and 802.11a clients) the Access Point can hear the signal on all antennas at the same time and then correlate or compare them all at the same time to enhance readability (that's essentially what MRC does). This has the benefit of hearing the signal much better in noisy or bad multi-path environments where a single antenna (receiver) would be problematic.
    To put it into more simple terms... Think of a conventional (non-802.11n) AP much like an old fashioned television with "rabbit ear" antennas... when you are watching and the picture is not so good you can see "ghosts" images slightly off from the image that you are viewing. To fix that "multi-path" problem that is caused by the TV signal reflecting off of objects, you physically move the rabbit ear type antenna so as to minimize reflections. The Access Point basically does the same thing but rather then physically moving the antenna (like in the case of the TV) it electrically moves the antenna by switching to the other antenna on the Access Point.
    Now with 802.11n (instead of this electrical switching of the antenna) think of several antennas with a method that dynamically "puts" all of these antennas together (without having to choose just one) for best performance. This is why all clients including older 802.11a/g clients benefit from this method.
    So when it comes to antenna placement, you can look at multiples of a given wavelength but it's not nearly as critical as you might think. Basically you don't want the antennas so far apart that they cover different cell sizes - and they could (but shouldn't be) any closer then they are on the AP-1250 AP which is approximately 2 & 3/4 inches.
    If you put them much closer then that, you run the risk that the Dipole elements will play off each other and perhaps take on additional directional properties.
    Fred Niehaus N8CPI
    TME Cisco WNBU.

  • flexunit 4.1 B3 Ant task fails to run Air-based tests

    Folks,
    I am using FlexUnit4.1 Beta 3 and am seeing the <flexunit> Ant task fail when running tests that use the Air libraries. The project in question used to test just fine with version 4.0 earlier this year, but I just dusted it off after a branch change and tried re-running with 4.1and started seeing the failure.Here is the relevant console output:
    [com.djte.library:flexunit] Validating task attributes ...
    [com.djte.library:flexunit] Generating default values ...
    [com.djte.library:flexunit] Using default working dir [C:\EclipseWorkspace3.5\report.renderer_tests_2\Source\Flex]
    [com.djte.library:flexunit] Using the following settings for the test run:
    [com.djte.library:flexunit]     FLEX_HOME: [C:\iFABS_DE\dev\vert-d3flxcmn24\204100.32.0.20100926233508_d3flxcmn24]
    [com.djte.library:flexunit]     haltonfailure: [false]
    [com.djte.library:flexunit]     headless: [false]
    [com.djte.library:flexunit]     display: [99]
    [com.djte.library:flexunit]     localTrusted: [true]
    [com.djte.library:flexunit]     player: [air]
    [com.djte.library:flexunit]     port: [1024]
    [com.djte.library:flexunit]     swf: [C:\EclipseWorkspace3.5\report.renderer_tests_2\build\report.renderer.tests.unit.swf]
    [com.djte.library:flexunit]     timeout: [1800000ms]
    [com.djte.library:flexunit]     toDir: [C:\EclipseWorkspace3.5\report.renderer_tests_2\build\reports\xml]
    [com.djte.library:flexunit] Setting up server process ...
    [com.djte.library:flexunit] Starting server ...
    [com.djte.library:flexunit] OS: [Windows]
    [com.djte.library:flexunit] Opening server socket on port [1024].
    [com.djte.library:flexunit] Waiting for client connection ...
    [com.djte.library:flexunit] Launching player:
    [com.djte.library:flexunit] Found AIR version: 1.5
    BUILD FAILED
    C:\public\JavaTools\DJTE\latest\DjteLibrary\library.xml:57: The following error occurred while executing this line:
    : Error launching the test runner.
    The error message is not very specific... The last output seen before the failure is "Found AIR version: 1.5". This makes me wonder if the problem is related to how I have Air installed on my Windows XP machine. Come to think of it, I am not sure exactly how the host machine should be configured to run FlexUnit tests that require Air.  Do I really need Air to be installed?  I have Air 2.0.3.13070 installed, but the <flexunit> task thinks it found version 1.5 - hmmm...  I also have the debug Flash 10 player, and SWF appplications are configued to run using this player. Flex tests run fine, just not Air tests.  What am I missing?
    I see that 4.1 RC1 is now out, so I will grab that and give it a try.
    If anyone who tests air more often has any advice - I am all ears!
    Thanks,
    Trevor

    Thanks for your responses, Brian!
    Yes, I think I see the immediate problem.  The problem is that there is no Air runtime in our customized Flex SDK (based on 3.2), even though it appears to have the Air compile libraries. I had been attempting to use this custom SDK to run FlexUnit with, and I think that needs to change.
    Why was I doing this?
    Well, I had tripped over some problems with 4.1 earlier on when I attempted to run it without having FLEX_HOME set in the environment. So, now I have been setting FLEX_HOME programmatically in my code before calling the <flexunit> task. And I had figured that it would be a good idea to set FLEX_HOME to the same SDK that the tests had been built with, i.e. our customized one.  Now I am thinking that this is not necessary, since our end users will never have access to this SDK. I now think that I should be able to install a new stock Adobe Flex SDK on my CI server, install the Air runtime into it, and then use that location when I set FLEX_HOME.  Is that how others are doing it?  If anyone could validate this approach, I would be grateful.
    One question that arises in my mind now: How does the Air runtime get into the Flex SDK? I have installed the Air runtime using the installer from Adobe some time ago, so I am not quite sure what all that did.  I assume the  Air installer finds all the Flex SDKs on your machine and inserts the runtime in each location appropriately? Again, pardon my ignorance...
    I have just tried out the above idea, i.e. setting FLEX_HOME to a different SDK that has Air runtime, and the <flexunit> task worked when I ran it!  An Air window opened, the tests ran, and reports were generated. So, it would appear my problem is solved! Cool beans!
    Brian, you made some comments about another possible issue with the "custom app descriptor".  I am not sure if that applies to me or not.  How would I know whether or not we need that support?  Again, I know it would help if I was the developer who had actually written the Flex tests, but I am not...
    Anyway, I hope this thread helps other folks who are having similar issues.  I am going to reinstall a fresh Adobe SDK and the Air installer on a clean machine next, and see if the tests will run there.
    Before ending this thread, I do want to point out that the ant task might have need of improvement in the case in which the user attempts to run the air "player" but the Air runtime is not setup in the SDK. On Windows, the ant process simply hung at this point, apparently thinking that the launch of the player had been successful, but in reality, the message about the air runtime being not found had occurred. It might be nice if it exited gracefully with a warning message instead of hanging. Just a suggestion...
    Brian, as always, thanks again for your help with this issue.You guys are doing a great job with this project. Please keep it up!
    Thanks,
    Trevor

  • Java.lang.NullPointerException running flexunit ant task in 4.1 Beta 2

    Hello,
    After trying to debug this all day, I thought I would ask the community.
    I am trying out the new FU4.1 Beta 2 (3.5) from the downloads page.  We have a working CI system set up with 4.0, and I thought trying out 4.1 beta 2 would simply be a matter of replacing the binaries in my lib folder and re-running the ant script.  Evidently not, or else I am missing something.
    After updating to the 4.1 Beta 2 binaries, if I re-run a sample project in Eclipse, the build fails with a java NullPointerException when the <flexunit> ant task is invoked. We have an involved setup that uses the groovy AntBuilder and other esoteric constructs, so I thought I would create a very simple test script similar to the sample CI project to see if that would work.  Unfortunately, I am still seeing the NPE.  The worst part is that there is absolutely no debug information provided - no message, no traceback.  I even attached the Ant source and debugged it. I could see the NPE being caught, but it contained a null message and null traceback.
    Here is the simplified ant script:
    <project name="tests" basedir=".">
        <target name="test-init" depends="">
            <mkdir dir="${build.dir}"/>
            <mkdir dir="${reports.dir}"/>
            <mkdir dir="${reports.xml}"/>
            <mkdir dir="${reports.html}"/>
            <!-- Setup Flex and FlexUnit ant tasks -->
            <!-- You can set this directly so mxmlc will work correctly, or set
            <taskdef resource="flexUnitTasks.tasks" classpath="${lib}/flexUnitTasks-4.1.0-beta2.18.jar" />
        </target>
        <target name="run-flex-tests" depends="test-init">
          <sequential>
            <!-- Execute TestRunner.swf as FlexUnit tests and publish reports -->
            <flexunit
                swf="${build.dir}/TestRunner.swf"
                toDir="${reports.xml}"
                haltonfailure="false"
                verbose="true"
                localTrusted="true"
                timeout="60000"/>
            <!-- Generate readable JUnit-style reports -->
            <junitreport todir="${reports.xml}">
                <fileset dir="${reports.xml}">
                    <include name="TEST-*.xml" />
                </fileset>
                <report format="frames" todir="${reports.html}" />
            </junitreport>
          </sequential>   
        </target>
    </project>
    The output is:
    Buildfile: C:\EclipseWorkspace\tests\Source\Flex\build_test.xml
    test-init:
    run-flex-tests:
    [flexunit] Validating task attributes ...
    BUILD FAILED
    C:\EclipseWorkspace\tests\Source\Flex\build_test.xml:23: java.lang.NullPointerException
    Total time: 297 milliseconds
    Is there something obvious I am missing?
    Thanks for any help!
    Trevor

    Brian,
    OK, a colleague worked with me (thanks, John!) to debug the problem a little further, and I think we found the fundamental problem.  I wanted to post that info to save you some time...
    Aside: One thing we did have to do was to rebuild the flexUnitTasks.jar to include debug information, since the binary in the 4.1 beta 2 package did not have debug=true.  I'd suggest that we might want to change the build script to build the binaries with debug moving forward.
    Back to the problem.
    The NullPointerException is thrown in TaskConfiguration::validateSharedProperties(), when equals() is invoked. Here is the code snippet:
       //if we can't find the FLEX_HOME and we're using ADL or compilation
       if((flexHome == null || !flexHome.exists()) && (testRunConfiguration.getPlayer().equals("air") || shouldCompile()))
          throw new BuildException("Please specify, or verify the location for, the FLEX_HOME property.  "
                + "It is required when testing with 'air' as the player or when using the 'testSource' element.  "
                + "It should point to the installation directory for a Flex SDK.");
    In my case, I do not have a FLEX_HOME property set in Ant currently.  I'll bet most folks have this set, so the logic would run differently for them. For my case, the (flexHome == null) check is true.  That means that the testRunConfiguration.getPlayer().equals("air")check will occur next, and here is the problem. The "player" member is not set in the testRunConfiguration yet at this point, so testRunConfiguration.getPlayer() returns null. testRunConfiguration.setPlayer() is called in generateDefaults().  But generateDefaults() is not called until after validateSharedProperties() is called.  So, if properties initialization could be improved here and I think this code will run more robustly.
    I can work-around my issue temporarily by just setting a FLEX_HOME property in Ant.  But I hope you will agree that the initialization issue with "player" still should be addressed. Would you like me to open a bug report, or is this thread enough?
    Thanks,
    Trevor

Maybe you are looking for

  • ITunes not appearing correctly

    I recently downloaded the latest version of iTunes onto my PC, running on Windows XP. Once it was downloaded and installed I opened it and it doesn't appear correctly. I can see images of albums, etc on the home page for the iTunes Store. But I canno

  • I have already download mozila but some web site not open

    some web site not open on my handset

  • Imovie help?

    I created a movie in imovie. I went to share>iDVD thinking this is what I must do according to some things I have read. I want to make a dvd from my finished product in imovie. How do I do that? I do not wish to use iDVD to make my movie. Help please

  • Two ways to get dynamic text into my s:RichEditableText

    font styling doesnt work with.. textFlow="{TextConverter.importToFlow( articleText, TextConverter.TEXT_FIELD_HTML_FORMAT )}" images dont work with.. textFlow="{TextFlowUtil.importFromString(articleTe  xt)} the problem is one way shows the images i ha

  • Detail log display error

    Hello, In the R3 system (4.6C, BRCONNECT 6.20 patch level 136, TOOLS HP-UX 11.23, oracle 9.2),  we have scheduled a job CleanupLogs in DB13. The program works successfully but while displaying details logs following error occures. BR252E Function fop