Xunit

In my application, the business logic is written in the page_load function itself and it does not return anything(void). In the page load, web method is called and the object is displayed on the ASP page. In any of these scenarios, no return type methods are used. All the methods are void type only. So, I think its not possible to implement nunit in this scenario. Please suggest.
Hi,
I am implementing nunit in my project. I am not getting idea how to implement the nunit after studying the documentation on it. Most of my code is:
private void Page_Load(object sender, System.EventArgs e)
logger.Info("Loading the AgentDetails page");
this.InitialiseRequest();
//this.Title = "Agent Details";
this.SetHeaderTabs(HeaderTabs1,1);
logger.Info("Webservice method 'getAgentDetails' is called from the Web References layer");
WSLayer.AgentDetails agtDet = this.WebService.getAgentDetails(this.AgentCode);
this.AgentName = agtDet.Subagent[0].Fullname;
this.SetTitleBar(HeaderTitleBar1);
this.SetAgentDetails(AgentDetails1);
logger.Info("End of Loading the AgentDetails page");
Could you please suggest me here? Can I write asserts inside this block itself?

bobz wrote:
In my application, the business logic is written in the page_load function itself and it does not return anything(void). First of all: you're in an entirely wrong forum for this question (and you should know that, as you've seem to be around for some time already).
Next: bundling your presentation layer with your logic is a terrible idea in all systems and is pretty un-testable. Extract your business logic into their own classes and only call those from your page_load (whatever that is). Then you can also test it easily.

Similar Messages

  • XUnit Tests not running

    Hello,
    A couple of days ago my xunit tests were happily running on build in the  TF Service, but suddenly not - can see exactly when.
    I cannot be sure whats caused this and tried to sort it out using info from this blog post
    http://blogs.msdn.com/b/visualstudioalm/archive/2012/03/27/build-on-the-team-foundation-service.aspx
    but no joy.
    I get a warning
    "No test is available in C:\a\bin\[AssemblyName].Tests.dll. Make sure that installed test discoverers &
    executors, platform & framework version settings are appropriate and try again."
    What could be going wrong?
    What information can I supply to help diagnose the problem?
     Many thanks
    Ant

    Hi Ant,
    I contact with Anjana that she has got your email, and sent response email to you. Please check your email box. Based on Anjana work with you via email, I temporarily close this case. I mark useful post as answer, it will be very beneficial for other
    community members having the similar questions.
    If anything is unclear, please free feel to let me know.
    Best Regards,
    Lily Wu
    MSDN Community Support | Feedback to us
    Develop and promote your apps in Windows Store
    Please remember to mark the replies as answers if they help and unmark them if they provide no help.

  • Empty Report File

    Obviously I'm doing something wrong because I can build my FlexUnit instance in ANT and get the verbose response that shows there were errors or not (I am using a simple test case and the SampleTests provided). Yet when I go to the report response (TESTS-TestSuites.xml) the file is empty:
    <?xml version="1.0" encoding="UTF-8" ?>
    <testsuites />
    I can run the FlexUnit4SampleCIProject and get the appropriate failures and report file, but not with my file. Any ideas why?
    I extended my tests to be more than just one because I saw at one point there was a bug with that.
    My ANT segment (my compile is earlier and successful):
        <target name="executeTestRunner" description="executes the test runner app">
            <echo>Running Test Runner SWF</echo>
            <flexunit swf="${Test.dir}/${TestRunner.name}.swf"
                toDir="${Report.dir}"
                haltonfailure="false"
                verbose="true"
                localTrusted="true"/>
            <echo>Ran Test Runner SWF</echo>
            <echo>Generate Readable Tests</echo>
            <junitreport todir="${Report.dir}">
                <fileset dir="${Report.dir}">
                    <include name="Test-*.xml"/>
                </fileset>
                <report format="frames" todir="${Report.dir}/html"/>
            </junitreport>
            <echo>Generated Readable Tests</echo>
        </target>
    The FlexUnit4SampleCIProject's ANT segment:
        <target name="test" depends="compile">
            <!-- Compile TestRunner.mxml as a SWF -->
            <mxmlc file="${test.src.loc}/TestRunner.mxml" output="${bin.loc}/TestRunner.swf">
                <source-path path-element="${main.src.loc}" />
                <library-path dir="${lib.loc}" append="true">
                    <include name="*.swc" />
                </library-path>
                <compiler.verbose-stacktraces>true</compiler.verbose-stacktraces>
                <compiler.headless-server>true</compiler.headless-server>
            </mxmlc>
            <!-- Execute TestRunner.swf as FlexUnit tests and publish reports -->
            <flexunit swf="bin/TestRunner.swf" toDir="${report.loc}" haltonfailure="false" verbose="true" localTrusted="true" />
            <!-- Generate readable JUnit-style reports -->
            <junitreport todir="${report.loc}">
                <fileset dir="${report.loc}">
                    <include name="TEST-*.xml" />
                </fileset>
                <report format="frames" todir="${report.loc}/html" />
            </junitreport>
        </target>
    Also, there is an error that the file FlashPlayerTrust is missing, shouldn't the flexUnitTasks.jar build that file if missing? I added it manually and it fixed the problem.

    Not a problem, already was generated.
    flashlog.txt
    <testcase classname='tests.unitedmindset.components::SuperLabelTest' name='testSetEmptyText' time='0.000'  status='success'/>
    <testcase classname='tests.unitedmindset.components::SuperLabelTest' name='testSetNullText' time='0.000'  status='failure'><failure message='expected:&lt;Super &gt; but was:&lt;Super null&gt;' type='tests.unitedmindset.components::SuperLabelTest.testSetNullText' ><![CDATA[expected:&lt;Super &gt; but was:&lt;Super null&gt;
        at org.flexunit::Assert$/failWithUserMessage()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\Fl exUnit4\src\org\flexunit\Assert.as:277]
        at org.flexunit::Assert$/failNotEquals()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit 4\src\org\flexunit\Assert.as:99]
        at org.flexunit::Assert$/assertEquals()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4 \src\org\flexunit\Assert.as:90]
        at tests.unitedmindset.components::SuperLabelTest/testSetNullText()[C:\workspace\ANTBuildUni tTest\src\tests\unitedmindset\components\SuperLabelTest.as:60]
        at Function/http://adobe.com/AS3/2006/builtin::apply()
        at flex.lang.reflect::Method/apply()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\sr c\flex\lang\reflect\Method.as:208]
        at ReflectiveCallable/run()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\fle xunit\runners\model\FrameworkMethod.as:297]
        at org.flexunit.runners.model::FrameworkMethod/applyExplosivelyAsync()[E:\hudson\jobs\FlexUn it4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\runners\model\FrameworkMethod.as:171]
        at org.flexunit.runners.model::FrameworkMethod/invokeExplosivelyAsync()[E:\hudson\jobs\FlexU nit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\runners\model\FrameworkMethod.as:186]
        at org.flexunit.internals.runners.statements::InvokeMethod/evaluate()[E:\hudson\jobs\FlexUni t4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\InvokeMethod. as:77]
        at org.flexunit.internals.runners.statements::StackAndFrameManagement/evaluate()[E:\hudson\j obs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\St ackAndFrameManagement.as:129]
        at org.flexunit.internals.runners.statements::StatementSequencer/executeStep()[E:\hudson\job s\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\Stat ementSequencer.as:97]
        at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\ statements\StatementSequencer.as:134]
        at org.flexunit.token::AsyncTestToken/sendResult()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspac e\FlexUnit4\src\org\flexunit\token\AsyncTestToken.as:118]
        at org.flexunit.internals.runners.statements::AsyncStatementBase/sendComplete()[E:\hudson\jo bs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\Asy ncStatementBase.as:76]
        at org.flexunit.internals.runners.statements::StatementSequencer/sendComplete()[E:\hudson\jo bs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\Sta tementSequencer.as:165]
        at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\ statements\StatementSequencer.as:138]
        at org.flexunit.token::AsyncTestToken/sendResult()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspac e\FlexUnit4\src\org\flexunit\token\AsyncTestToken.as:118]
        at org.flexunit.internals.runners.statements::InvokeMethod/handleMethodExecuteComplete()[E:\ hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\state ments\InvokeMethod.as:89]
        at org.flexunit.token::AsyncTestToken/sendResult()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspac e\FlexUnit4\src\org\flexunit\token\AsyncTestToken.as:118]
        at org.flexunit.runners.model::FrameworkMethod/applyExplosivelyAsync()[E:\hudson\jobs\FlexUn it4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\runners\model\FrameworkMethod.as:173]
        at org.flexunit.runners.model::FrameworkMethod/invokeExplosivelyAsync()[E:\hudson\jobs\FlexU nit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\runners\model\FrameworkMethod.as:186]
        at org.flexunit.internals.runners.statements::InvokeMethod/evaluate()[E:\hudson\jobs\FlexUni t4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\InvokeMethod. as:77]
        at org.flexunit.internals.runners.statements::SequencerWithDecoration/executeStep()[E:\hudso n\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements \SequencerWithDecoration.as:104]
        at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\ statements\StatementSequencer.as:134]
        at org.flexunit.internals.runners.statements::StatementSequencer/evaluate()[E:\hudson\jobs\F lexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\Stateme ntSequencer.as:108]
        at org.flexunit.internals.runners.statements::StatementSequencer/executeStep()[E:\hudson\job s\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\Stat ementSequencer.as:97]
        at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\ statements\StatementSequencer.as:134]
        at org.flexunit.internals.runners.statements::StatementSequencer/evaluate()[E:\hudson\jobs\F lexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\Stateme ntSequencer.as:108]
        at org.flexunit.runners::BlockFlexUnit4ClassRunner/runChild()[E:\hudson\jobs\FlexUnit4-Flex3 .4\workspace\FlexUnit4\src\org\flexunit\runners\BlockFlexUnit4ClassRunner.as:130]
        at org.flexunit.internals.runners::ChildRunnerSequencer/executeStep()[E:\hudson\jobs\FlexUni t4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\ChildRunnerSequencer.as: 82]
        at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\ statements\StatementSequencer.as:134]
        at org.flexunit.token::AsyncTestToken/sendResult()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspac e\FlexUnit4\src\org\flexunit\token\AsyncTestToken.as:118]
        at org.flexunit.runners::BlockFlexUnit4ClassRunner/handleBlockComplete()[E:\hudson\jobs\Flex Unit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\runners\BlockFlexUnit4ClassRunner.as:16 7]
        at org.flexunit.token::AsyncTestToken/sendResult()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspac e\FlexUnit4\src\org\flexunit\token\AsyncTestToken.as:118]
        at org.flexunit.internals.runners.statements::AsyncStatementBase/sendComplete()[E:\hudson\jo bs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\Asy ncStatementBase.as:76]
        at org.flexunit.internals.runners.statements::StatementSequencer/sendComplete()[E:\hudson\jo bs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\Sta tementSequencer.as:165]
        at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\ statements\StatementSequencer.as:138]
        at org.flexunit.token::AsyncTestToken/sendResult()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspac e\FlexUnit4\src\org\flexunit\token\AsyncTestToken.as:118]
        at org.flexunit.internals.runners.statements::AsyncStatementBase/sendComplete()[E:\hudson\jo bs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\Asy ncStatementBase.as:76]
        at org.flexunit.internals.runners.statements::StatementSequencer/sendComplete()[E:\hudson\jo bs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\Sta tementSequencer.as:165]
        at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\ statements\StatementSequencer.as:138]
        at org.flexunit.token::AsyncTestToken/sendResult()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspac e\FlexUnit4\src\org\flexunit\token\AsyncTestToken.as:118]
        at org.flexunit.internals.runners.statements::InvokeMethod/handleMethodExecuteComplete()[E:\ hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\state ments\InvokeMethod.as:89]
        at org.flexunit.token::AsyncTestToken/sendResult()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspac e\FlexUnit4\src\org\flexunit\token\AsyncTestToken.as:118]
        at org.flexunit.runners.model::FrameworkMethod/applyExplosivelyAsync()[E:\hudson\jobs\FlexUn it4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\runners\model\FrameworkMethod.as:173]
        at org.flexunit.runners.model::FrameworkMethod/invokeExplosivelyAsync()[E:\hudson\jobs\FlexU nit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\runners\model\FrameworkMethod.as:186]
        at org.flexunit.internals.runners.statements::InvokeMethod/evaluate()[E:\hudson\jobs\FlexUni t4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\InvokeMethod. as:77]
        at org.flexunit.internals.runners.statements::SequencerWithDecoration/executeStep()[E:\hudso n\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements \SequencerWithDecoration.as:104]
        at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\ statements\StatementSequencer.as:134]
        at org.flexunit.internals.runners.statements::StatementSequencer/evaluate()[E:\hudson\jobs\F lexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\Stateme ntSequencer.as:108]
        at org.flexunit.internals.runners.statements::StatementSequencer/executeStep()[E:\hudson\job s\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\Stat ementSequencer.as:97]
        at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\ statements\StatementSequencer.as:134]
        at org.flexunit.token::AsyncTestToken/sendResult()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspac e\FlexUnit4\src\org\flexunit\token\AsyncTestToken.as:118]
        at org.flexunit.internals.runners.statements::StackAndFrameManagement/handleNextExecuteCompl ete()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runn ers\statements\StackAndFrameManagement.as:151]
        at org.flexunit.token::AsyncTestToken/sendResult()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspac e\FlexUnit4\src\org\flexunit\token\AsyncTestToken.as:118]
        at org.flexunit.internals.runners.statements::InvokeMethod/handleMethodExecuteComplete()[E:\ hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\state ments\InvokeMethod.as:89]
        at org.flexunit.token::AsyncTestToken/sendResult()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspac e\FlexUnit4\src\org\flexunit\token\AsyncTestToken.as:118]
        at org.flexunit.runners.model::FrameworkMethod/applyExplosivelyAsync()[E:\hudson\jobs\FlexUn it4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\runners\model\FrameworkMethod.as:173]
        at org.flexunit.runners.model::FrameworkMethod/invokeExplosivelyAsync()[E:\hudson\jobs\FlexU nit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\runners\model\FrameworkMethod.as:186]
        at org.flexunit.internals.runners.statements::InvokeMethod/evaluate()[E:\hudson\jobs\FlexUni t4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\InvokeMethod. as:77]
        at org.flexunit.internals.runners.statements::StackAndFrameManagement/evaluate()[E:\hudson\j obs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\St ackAndFrameManagement.as:129]
        at org.flexunit.internals.runners.statements::StatementSequencer/executeStep()[E:\hudson\job s\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\Stat ementSequencer.as:97]
        at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\ statements\StatementSequencer.as:134]]]></failure></testcase>
    <testcase classname='tests.unitedmindset.components::SuperLabelTest' name='testSetHelloWorldText' time='0.000'  status='success'/>
    <testcase classname='tests.unitedmindset::SampleTest' name='testSampleError' time='0.000'  status='error'><error message='ERROR! - This is an error' type='tests.unitedmindset::SampleTest.testSampleError' ><![CDATA[Error: ERROR! - This is an error
        at tests.unitedmindset::SampleTest/testSampleError()[C:\workspace\ANTBuildUnitTest\src\tests \unitedmindset\SampleTest.as:18]
        at Function/http://adobe.com/AS3/2006/builtin::apply()
        at flex.lang.reflect::Method/apply()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\sr c\flex\lang\reflect\Method.as:208]
        at ReflectiveCallable/run()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\fle xunit\runners\model\FrameworkMethod.as:297]
        at org.flexunit.runners.model::FrameworkMethod/applyExplosivelyAsync()[E:\hudson\jobs\FlexUn it4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\runners\model\FrameworkMethod.as:171]
        at org.flexunit.runners.model::FrameworkMethod/invokeExplosivelyAsync()[E:\hudson\jobs\FlexU nit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\runners\model\FrameworkMethod.as:186]
        at org.flexunit.internals.runners.statements::InvokeMethod/evaluate()[E:\hudson\jobs\FlexUni t4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\InvokeMethod. as:77]
        at org.flexunit.internals.runners.statements::StackAndFrameManagement/handleTimerComplete()[ E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\st atements\StackAndFrameManagement.as:141]
        at flash.events::EventDispatcher/dispatchEventFunction()
        at flash.events::EventDispatcher/dispatchEvent()
        at flash.utils::Timer/tick()]]></error></testcase>
    <testcase classname='tests.unitedmindset::SampleTest' name='testSampleFailure' time='0.000'  status='failure'><failure message='FAIL! - This is a sample test that will fail.' type='tests.unitedmindset::SampleTest.testSampleFailure' ><![CDATA[FAIL! - This is a sample test that will fail.
        at org.flexunit::Assert$/fail()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org \flexunit\Assert.as:265]
        at tests.unitedmindset::SampleTest/testSampleFailure()[C:\workspace\ANTBuildUnitTest\src\tes ts\unitedmindset\SampleTest.as:12]
        at Function/http://adobe.com/AS3/2006/builtin::apply()
        at flex.lang.reflect::Method/apply()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\sr c\flex\lang\reflect\Method.as:208]
        at ReflectiveCallable/run()[E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\fle xunit\runners\model\FrameworkMethod.as:297]
        at org.flexunit.runners.model::FrameworkMethod/applyExplosivelyAsync()[E:\hudson\jobs\FlexUn it4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\runners\model\FrameworkMethod.as:171]
        at org.flexunit.runners.model::FrameworkMethod/invokeExplosivelyAsync()[E:\hudson\jobs\FlexU nit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\runners\model\FrameworkMethod.as:186]
        at org.flexunit.internals.runners.statements::InvokeMethod/evaluate()[E:\hudson\jobs\FlexUni t4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\statements\InvokeMethod. as:77]
        at org.flexunit.internals.runners.statements::StackAndFrameManagement/handleTimerComplete()[ E:\hudson\jobs\FlexUnit4-Flex3.4\workspace\FlexUnit4\src\org\flexunit\internals\runners\st atements\StackAndFrameManagement.as:141]
        at flash.events::EventDispatcher/dispatchEventFunction()
        at flash.events::EventDispatcher/dispatchEvent()
        at flash.utils::Timer/tick()]]></failure></testcase>
    <testcase classname='tests.unitedmindset::SampleTest' name='testSampleIgnore' time='0.000' status='ignore'><skipped /></testcase>
    <endOfTestRun/>
    SuperLabelTest.as (runs as intended in UIListener)
    this meant to be a simple test class, nothing real or production level
    package tests.unitedmindset.components
        import com.unitedmindset.components.SuperLabel;
        import org.flexunit.Assert;
        public class SuperLabelTest
            public function SuperLabelTest()
            // Private Vars
            private var superLabel:SuperLabel;
            // Setup
            [BeforeClass]
            public static function runBeforeClass():void
                //do nothing
            [AfterClass]
            public static function runAfterClass():void
                //do nothing
            [Before(order=1)]
            public function runBeforeEveryTest():void
                superLabel = new SuperLabel();
            [After]
            public function runAfterEveryTest():void
                superLabel = null;
            // Tests
            [Test(description="Tests Setting 'Hello World' Text in SuperLabel")]
            public function testSetHelloWorldText():void
                superLabel.text = "Hello World";
                Assert.assertEquals("Super Hello World", superLabel.text);
            [Test(description="Tests Setting NULL in SuperLabel")]
            public function testSetNullText():void
                superLabel.text = null;
                //fail
                Assert.assertEquals("Super ", superLabel.text);
                //pass
                //Assert.assertEquals("Super null", superLabel.text);
            [Test(description="Tests Setting '' in SuperLabel")]
            public function testSetEmptyText():void
                superLabel.text = "";
                Assert.assertEquals("Super ", superLabel.text);

  • XI Http adapter receiver issue, how to change the target payload format

    Dear all,
    In my project, I need to call a servlet program using Http/xml.
    The message format accepted by the server program is like this:
    request:
    <?xml version="1.0" encoding="GBK"?>
    <PACKET type="REQUEST" version="1.0" >
    <HEAD>
      <REQUEST_TYPE>01</REQUEST_TYPE>
    </HEAD>
    <BODY>
      <BASE_PART>
        <QUERY_SEQUENCE_NO></QUERY_SEQUENCE_NO>
      </BASE_PART>
    </BODY>
    </PACKET>
    response:
    <?xml version="1.0" encoding="GB2312"?>
    <PACKET type="RESPONSE" version="1.0" >
    <HEAD>
      <REQUEST_TYPE>01</REQUEST_TYPE>
      <RESPONSE_CODE>1</RESPONSE_CODE>
      <ERROR_CODE>0000</ERROR_CODE>
      <ERROR_MESSAGE>xxx</ERROR_MESSAGE>
    </HEAD>
    <BODY>
      <BASE_PART>
        <QUERY_SEQUENCE_NO>01PICC057106001156421487812453</QUERY_SEQUENCE_NO>
      </BASE_PART.
    </BODY>
    <PACKET>
    My first question is if I can use the servie by SAP PI http adapter?
    If yes, and how to design the data type? The <HEAD> <BODY> are on the same level...
    Commonly, I only can set the data type like this:
    <?xml version="1.0" encoding="UTF-8"?>
    <MT_HTTP_IN>
       <HEAD>
          <REQUEST_TYPE>1</REQUEST_TYPE>
       </HEAD>
       <BODY>
          <BASE_PART>
             <QUERY_SEQUENCE_NO>123</QUERY_SEQUENCE_NO>
          </BASE_PART>
       </BODY>
    </MT_HTTP_IN>
    The problem is how to remove the <MT_HTTP_IN> then insert the tab <PACKET  type="REQUEST" version="1.0" >? I wonder if I need use JAVA mapping? and could u give me a related samples?
    Thanks a lot!

    Dear Xun Liu,
       If you need <PACKET type="REQUEST" version="1.0" >, then you need to create attributes 'type' and 'version' under node <PACKET>. At mapping level you can pass constant values for those attibutes.
    Regards,
    JP.

  • Composer Process Report XML Format

    Hi,
    We generated 'Process Report' -- XML format in Oracle BPM Composer. After generating saved content in a xml file. When tried to open this file, getting error message like not in proper xml format etc., Have we missed any thing in installing or configuring Composer. pleased suggest.
    -- Thanks .... Murthy

    @trevorbutler -  Could you send us what version of Ant you're using and a  sample of how you're using the <junit> Ant task?  Additionally,  can you validate that the example you gave for the JUnit output is from  the <junit> Ant task and not the <junitreport> task?  Could you also let us know which version of JUnit you used with Ant, just in case?
    FWIW - The XML output that you see from running tests in JUnit via the <junit> Ant task is output that has been defined without specification by the folks at Apache Ant.  There has been a lot of discussion on standardizing the output amongst the folks at TestNG, the Maven Surefire plugin and others, but I haven't seen anything standardized come out of that.  Here is a wiki page that has some of that discussion http://wiki.apache.org/ant/Proposals/EnhancedTestReports.  t's also important to note, that the aggregate results of the <junitreport> task contain a slight variation on the output produced by the <junit> task.  Consequently, we have to emulate the lowest common denominator that we know will work with the tools out there that parse the XML output associated with an xUnit framework (e.g. - Ant tasks, CI server, etc).  This being said, we rely on the community to keep us up to date with variations that we may have missed or for which need to update.  It's not so much that we've decided to exclude any particular elements from the output, we just need help fine tuning as time goes on.
    Thanks for the help.
    -Brian

  • 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.

  • Reading s file and saving a the dta to an array

    Hi,
    I have a txt file that is contained of text and numbersso this is the format :
    hdfsgfjsgfjsfg
    kshfkwhfl
    kshfakh
    kahflak
    Xunit , YUNIT
    1,2
    2,3
    5,4
    So I want to read this file and save the numbers to two arrays, here is my code, and it gives error on Ch[i] = result[1]; it also say array out of bound and it gives me the watrning that ReadDile.java overrides a depricated API. hELP:
    import java.net.*;
    import java.io.*;
    import java.util.*;
    import java.lang.*;
    public class ReadFile {
    public static void main(String[] args) throws IOException {
    /*Open the file and Read the file
         File inputFile = new File("wfmdata.txt");
         FileReader in = new FileReader(inputFile); */
         FileInputStream fis = new FileInputStream("wfmdata.txt");
    BufferedInputStream bis = new BufferedInputStream(fis);
    DataInputStream dis = new DataInputStream(bis);
         String c;
         String[] T = new String[10012];
         String[] CH = new String[10012];
    int i=0;
    for(;;)
    /*Read one line and store it in variable c */
    c = dis.readLine();
    //if a null line return
    if(c != null)
    if( (c == "XUNIT , YUNIT"))
    continue;
    String[] result = c.toString().split(",");
    T[i] = result[1];
    CH[i] = result [1];
    System.out.println( T[i] + "," + "CH" + result.length);
    i++;
         }else
    dis.close();
    how would I change the code to get rid of the errors!
    there are 10000 lines of numbers(data).
    Sanaz,

    If you are only trying to read in integers i would recommend a different approach. Try using the scanner class. It's new to 1.5 It basically splits up everything in the data source into tokens based on where there is white space. what might interest you is that it has methods to just retrieve primitive types ints, doubles etc.
    http://java.sun.com/j2se/1.5.0/docs/api/java/util/Scanner.html
    you might try something like this. It will ignore strings and just handle integers, based on the format you have given.
    import java.util.Scanner;
    import java.io.*;
    public class ReadFile
        public static void readFile() throws FileNotFoundException
            Scanner sc = new Scanner(new FileReader("C:\\YourFile.txt")); // set the source of the data and create a scanner object to tokenize the data
            int[] xUnit = new int[10012]; // initialise the integer arrays
            int[] yUnit = new int[10012];
            while (sc.hasNextInt() == false) // checks to see if the next "token" read by the scanner is an integer
                sc.next(); // moves onto the next token until an int is found.
            for (int count = 0; count < xUnit.length; count ++)  // goes through the array until it hits the end
                xUnit[count] = sc.nextInt(); //assigns the int to the array
                sc.next(); // skips the comma
                yUnit[count] = sc.nextInt(); //assigns the next int to the other array
            for (int count = 0; count < xUnit.length; count ++)
                System.out.println( xUnit[count] + "," + yUnit[count]); //prints out all the data read in
    }Bear in mind my java experience is fairly limited, so this may not be what you're after.

  • Is it a bug? GridBagLayout  with textField

    Hi,
    The following method does not work fine.
    The textfield field gets all the space
    but if i change
    JTextField field = new JTextField();
    with
    JPanel field = new JPanel();
    it will work fine.
    I think there is a problem with GridBagLayout
    and textField. is it a bug in jdk1.2
    public JPanel getCPane() {
    int XUNIT = 5;
    int YUNIT = 100;
    JPanel pane = new JPanel();
    JPanel pane1 = new JPanel();
    JTextField field = new JTextField();
    pane1.setBackground(Color.red);
    pane1.setPreferredSize(new Dimension(2*XUNIT, YUNIT));
    field.setPreferredSize(new Dimension(6*XUNIT, YUNIT));
    pane.setLayout(new GridBagLayout());
    GridBagConstraints c = new GridBagConstraints();
    c.fill = GridBagConstraints.BOTH;
    c.insets = new Insets(0,0,0,0);
    c.weightx = c.weighty = 0;
    c.gridx = 0; c.gridy = 0;
    c.gridwidth = 2*XUNIT; c.gridheight = YUNIT;
    pane.add(pane1, c);
    c.weightx = c.weighty = 1;
    c.gridx = 2; c.gridy = 0;
    c.gridwidth = 6*XUNIT; c.gridheight = YUNIT;
    pane.add(field, c);
    return pane;

    Any solution please

  • Using function equivalent to sscanf in JAVA

    Hello,
    All I want to do in java is to read the data saved in a buffer( a lot of numbers and characters seperated by semicolons) and organize it into columns of data saved in an outfile!!!! To this end each number or character seperated by a " ; " from the other has a special meaning and I need to save each one in a seperate variable to be able to use it in later simulation.I also dont know how much data is saved in the string. I just know that it is there and I need to extract it to something HUMAN readable.
    So I have this string of numbers and letters saved in a buffer string s.
    500 ; -5.0E-1 ; 4.0E-3 ; 2.0E-8 ; 0 ; "s" ; "V"
    (ignore the spaces, I just wanted you to be able to read the characters easily)
    So if I was using C I would ve simply use sscanf
    sscanf( s , "%d;%e;%e;%e;%d;%[^;];%s", &nr_pt, &yoff, &ymult,
    &xincr, &pt_off, xunit,yunit );
    to read the data saved in s and save it to 7 other variables.
    But how would I do this in JAVA, so desperate! Do I use some functions like read or read line or....
    So here I knew that I have 7 variable, what if I do not know how many data points is saved in the string and I want to read one by one and save it or print it to a file!
    Thanks,
    Sanaz

    You can read the thing in as a String, and then use the String's "split" method to split that up into an array of substrings. Then you can deal with each substring individually, converting them to numeric types via Double.parseDouble() for example.
    Or you might want to look at the Scanner class.
    http://java.sun.com/j2se/1.5.0/docs/api/index.html

  • TDD - Abap

    Hi Collegues,
    I am new in Abap Development and I am trying to "port" some of my Agile Knowledges within this new world.
    The Abap Unit framework implementation of xUnit is a good point to start.
    A unit test is Unit if:
    - there is no db connection
    - it does no work with network
    - etc.
    I know, more depends by the way and intention of  unit test, but mock an object is really useful.
    Is there a way to create mock object in Abap? Something like EasyMock.
    Thanks for your replies.
    Regards,
    Mirco.

    Hello Mirco,
    as Sandra already told there is no automatic support for test doubles yet. All you can do is to write stubs, spies and mocks on your own.
    BTW: As in ABAP you get the DB connection for free, the definition for a Unit Test does not apply in full extend. 
    Best Regards
      Klaus

  • Question about cyrus-sasl2: sasldblistusers2 shows check_db unsuccessful

    I run "port install" to build cyrus-sasl2 without problems.
    saslpasswd2 creates the sasldb2 file, but shows an error message in the auth.log.
    error deleting entry from sasldb: DB_NOTFOUND: No matching key/data pair found
    Running sasldblistuser2 to list the user created with sasldb2 still not working and shows up "check_db unsuccessful".
    What causes the error ?
    root# port install cyrus-sasl2
    ---> Fetching cyrus-sasl2
    ---> Verifying checksum(s) for cyrus-sasl2
    ---> Extracting cyrus-sasl2
    ---> Configuring cyrus-sasl2
    ---> Building cyrus-sasl2
    ---> Staging cyrus-sasl2 into destroot
    ---> Installing cyrus-sasl2 @2.1.22_0
    ---> Activating cyrus-sasl2 @2.1.22_0
    ---> Cleaning cyrus-sasl2
    root# port installed | grep cyrus-sasl2
    cyrus-sasl2 @2.1.22_0 (active)
    root# saslpasswd2 -c -u localhost _cyrus
    Password:
    Again (for verification):
    root# ls -ltr /opt/local/etc/sasldb2
    -rw-r----- 1 root admin 12288 Mar 24 15:00 /opt/local/etc/sasldb2
    root# file /opt/local/etc/sasldb2
    /opt/local/etc/sasldb2: Berkeley DB (Hash, version 8, little-endian)
    root# sasldblistusers2
    check_db unsuccessful
    saslpasswd2 logs the following:
    What does it mean : error deleting entry from sasldb: DB_NOTFOUND: No matching key/data pair found
    Mar 24 15:00:19 mac02 saslpasswd2[42052]: Setpass for SRP successful
    Mar 24 15:00:19: --- last message repeated 2 times ---
    Mar 24 15:00:19 mac02 saslpasswd2[42052]: Setpass for OTP successful
    Mar 24 15:00:19: --- last message repeated 2 times ---
    Mar 24 15:00:19 mac02 saslpasswd2[42052]: error deleting entry from sasldb: DB_NOTFOUND: No matching key/data pair found
    sasldblistusers2 gives:
    Mar 24 15:01:42 mac02 sasldblistusers2[42062]: auxpropfunc error invalid parameter supplied
    Mar 24 15:01:42 mac02 sasldblistusers2[42062]: sasl_pluginload failed on saslauxprop_pluginit for plugin: ldapdb
    Mar 24 15:01:42 mac02 sasldblistusers2[42062]: auxpropfunc error invalid parameter supplied
    Mar 24 15:01:42 mac02 sasldblistusers2[42062]: sasl_pluginload failed on saslauxprop_pluginit for plugin: ldapdb
    Mar 24 15:01:42 mac02 sasldblistusers2[42062]: auxpropfunc error invalid parameter supplied
    Mar 24 15:01:42 mac02 sasldblistusers2[42062]: sasl_pluginload failed on saslauxprop_pluginit for plugin: ldapdb
    The shared libraries that the object uses:
    root# otool -L /opt/local/bin/saslpasswd2
    root# otool -L /opt/local/sbin/saslpasswd2
    /opt/local/sbin/saslpasswd2:
    /usr/lib/libresolv.9.dylib (compatibility version 1.0.0, current version 25.0.2)
    /usr/lib/libpam.1.dylib (compatibility version 1.0.0, current version 1.0.0)
    /opt/local/lib/libsasl2.2.dylib (compatibility version 3.0.0, current version 3.22.0)
    /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 111.1.3)
    /opt/local/lib/db44/libdb-4.4.dylib (compatibility version 0.0.0, current version 0.0.0)
    /usr/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current version 1.0.0)
    root# otool -L /opt/local/sbin/sasldblistusers2
    /opt/local/sbin/sasldblistusers2:
    /usr/lib/libresolv.9.dylib (compatibility version 1.0.0, current version 25.0.2)
    /usr/lib/libpam.1.dylib (compatibility version 1.0.0, current version 1.0.0)
    /opt/local/lib/libsasl2.2.dylib (compatibility version 3.0.0, current version 3.22.0)
    /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 111.1.3)
    /opt/local/lib/db44/libdb-4.4.dylib (compatibility version 0.0.0, current version 0.0.0)
    /usr/lib/libgcc_s.1.dylib (compatibility version 1.0.0, current version 1.0.0)

    Hi Xun,
    As a Workaround, you can try below:
    On the Target system, perform the following steps:
    1. Edit $ORACLE_HOME/appsutil/clone/context/db/CTXORIG.xml on db & $COMMON_TOP/clone/context/apps/CTXORIG.xml for apps
    2. Change the value for s_dbSid,s_contextname,s_dbhost to the correct target system value
    3. Rerun "perl adcfgclone.pl dbTier" & "perl adcfgclone.pl appsTier"

  • Throwing and catching deliberate errors in bash

    Hello,
    In many languages one can throw deliberate errors of a specific kind as well as catch-trap for specific errors. I'm having a hard time determining how to do this in bash 3.2 with it's 'trap' command.
    Moreover, I can't figure out whether or not if it's even possible to catch for specific thrown errors defined by a scripter in bash. My own tests have led to a dead end and I haven't come any better understanding from reading the bash info docs, and numerous online and in print examples of the 'trap' command.
    Basically, I wish to...
    1. First, have scripts throw a specifically, identifiable, unique error when a certain known bad state has been encountered that they can't handle.
    2. Secondly, to able to test for whether scripts are throwing an specific error under a certain condition.
    3. Trap for and catch only that specific error and then keep on going, performing further automated tests.
    Is this possible in bash?
    Below is an example which might better illustrate what I've attempted to do. It unfortunately, doesn't do what's needed at the moment. i.e.- It will catch all errors and exits but not a specific one.
    #--- The example below traps all errors but not the specific one.
    particular_function()
    current_status="some known bad condition"
    if [ "$current_status" = "some known bad condition" ]; then
    # Encountered some known condition we can't handle so throw specific error.
    echo "Encountered a, we knew this would happen, type error."
    exit -99
    fi
    testmethod_for_expectederror()
    trap 'echo "function threw expected error code as it should."' EXIT
    particular_function
    testmethod_for_expectederror
    echo "Continued passed caught error as desired and continuing further tests..."
    Thanks,
    -Anthony

    {quote:title=BobHarris wrote:}The bash trap statement was not intended as an alternate way to return errors.
    But if you want to generate your own signals, then use the kill command.
    See "man 1 kill". {quote}
    It sounds like I'm attempting to pound a square peg through a round hole? Attempting workarounds, like shaving off the corners of the peg, might eventually just lead to loss of sanity, time wasted - gone forever, never to return.
    So, perhaps I'll try some other method.
    If it offers a little more clarity, I'm trying determine [how to write tests|http://xp123.com/xplor/xp0101/index.shtml|Test-First Stoplight - write a test first before writing a line of code.], in bash, for situations where a script [should halt executing|http://xunitpatterns.com/Test%20Method.html#Expected%20Exception%20Te st|Expected exception test pattern] when it encounters something it can't handle rather than keep on going causing potential mishaps.
    Basically, I would like to avoid causing the [xUnit testing framework|http://www.martinfowler.com/bliki/Xunit.html|xUnit testing frameworks in XP] I'm using [(shUnit2)|http://code.google.com/p/shunit2/|shUnit2 project site] from incorrectly reporting expected errors, that are suppose to be thrown, by a script, as failures. An expected, [correctly thrown error|http://books.google.ca/books?id=gFgndevwMAC&pg=PA163&lpg=PA163&dq=%22exceptiontest%22+%22test+driven+development%22patterns&source=bl&ots=enHrtsSunH&sig=PbbvWbea_VkqVAbdGYZwJDUcygI&hl=en&ei=XQslS qzSDs-EmQfIvqCFCA&sa=X&oi=bookresult&ct=result&resnum=1|Catch expected exceptions and ignore them. in TDD by Kent Beck] should be counted as a success by the framework in that context. Assuming, the script didn't exit in a bad way. At the same time, unforeseen errors should not be blocked and should propagate up to be reported as an erring test.
    Thanks for your help,
    -Anthony

  • NIST conformance tests using JUnit

    I haven't seen anyone from Oracle on the [email protected] mailing list, so I'm posting this here just to let you guys know.
    I've been working on recasting the NIST DOM test suite for Java to use JUnit and posted an initial release last night.
    The tests can easily be run against the beta XDK's parser (or any other JAXP compliant parser), but there were a substantial number test errors and failures. Some of these may be due to test problems, but I'd guess most of them are legitimate. However, I do not have time or the motivation to investigate them.
    It does seem that you take the position that the XML declaration is treated as a processing instruction (like MSXML does) which will cause 3 tests to fail, but you can adjust the tests to accept this using
    -Dnet.sourceforge.xmlconf.domunit.acceptXMLDeclPI=true
    I've made the source for my JUnit-hosted deriviatives of the NIST test suite available at http://xmlconf.sourceforge.net. You can either download the combined source and binary
    zip file from http://sourceforge.net/project/showfiles.php?group_id=8114&release_id=31676
    or you can access the source through the CVS (http://sourceforge.net/cvs/?group_id=8114)
    The tests run using JUnit 3.5 and can test JAXP 1.0 or JAXP 1.1 compliant DOM parsers.
    Xerces-J 1.3.1 does not report any test failures, crimson.jar and the other parser tested
    had a moderate amount of test failures, but no investigation has been performed to
    determine if those failures were problems with the tests or actual non-conformances
    with the spec.
    A JBuilder 4 .jpx project and an Ant 1.2 build.xml file are provided.
    ------- readme.txt from domunit 0.0.1 ---------
    domunit 0.0.1
    domunit currently contains equivalents of the NIST DOM 1 test written for
    the JUnit test framework (http://www.junit.org) and JAXP 1.1 or 1.0 compatible parsers.
    The tests were written to allow easy migration to JavaScript using JSUnit
    (http://www.jsunit.net) and CPPUnit (http://www.xprogramming.org/software)
    To run the full set of tests, place domunit.jar, junit.jar and one of the following
    combinations of jars in the same directory or on the class path.
    xerces.jar
    xml4j.jar
    jaxp.jar and parser.jar (from Sun's JAXP 1.0 Reference Implementation)
    jaxp.jar and crimson.jar (from Sun's JAXP 1.1 Reference Implementation)
    and run:
    java -jar domunit.jar
    To test Oracle's XML Processor, place jaxp.jar from the JAXP 1.0 (not 1.1) Reference Implementation
    and xmlparserv2.jar in the domunit.jar directory and run:
    java -Djavax.xml.parsers.DocumentBuilderFactory=oracle.xml.jaxp.JXDocumentBuilderFactory
    -jar domunit.jar
    The following options can adjust the tests:
    -Dnet.sourceforge.xmlconf.domunit.isExpandEntityReferences=true
    -Dnet.sourceforge.xmlconf.domunit.isCoalescing=true
    -Dnet.sourceforge.xmlconf.domunit.acceptXMLDeclPI=true
    To build the project, use either the JBuilder 4 .jpx file or
    the Ant 1.2 build.xml file.
    Curt Arnold http://xmlconf.sourceforge.net
    [email protected]
    18 April 2001
    domunit - DOM testing on the xUnit frameworks
    Copyright (C) 2001, Curt Arnold
    This program is free software; you can redistribute it and/or
    modify it under the terms of the GNU General Public License
    as published by the Free Software Foundation; either version 2
    of the License, or (at your option) any later version.
    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    GNU General Public License for more details.
    You should have received a copy of the GNU General Public License
    along with this program; if not, write to the Free Software
    Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
    null

    I haven't seen anyone from Oracle on the [email protected] mailing list, so I'm posting this here just to let you guys know.
    I've been working on recasting the NIST DOM test suite for Java to use JUnit and posted an initial release last night.
    The tests can easily be run against the beta XDK's parser (or any other JAXP compliant parser), but there were a substantial number test errors and failures. Some of these may be due to test problems, but I'd guess most of them are legitimate. However, I do not have time or the motivation to investigate them.
    It does seem that you take the position that the XML declaration is treated as a processing instruction (like MSXML does) which will cause 3 tests to fail, but you can adjust the tests to accept this using
    -Dnet.sourceforge.xmlconf.domunit.acceptXMLDeclPI=true
    I've made the source for my JUnit-hosted deriviatives of the NIST test suite available at http://xmlconf.sourceforge.net. You can either download the combined source and binary
    zip file from http://sourceforge.net/project/showfiles.php?group_id=8114&release_id=31676
    or you can access the source through the CVS (http://sourceforge.net/cvs/?group_id=8114)
    The tests run using JUnit 3.5 and can test JAXP 1.0 or JAXP 1.1 compliant DOM parsers.
    Xerces-J 1.3.1 does not report any test failures, crimson.jar and the other parser tested
    had a moderate amount of test failures, but no investigation has been performed to
    determine if those failures were problems with the tests or actual non-conformances
    with the spec.
    A JBuilder 4 .jpx project and an Ant 1.2 build.xml file are provided.
    ------- readme.txt from domunit 0.0.1 ---------
    domunit 0.0.1
    domunit currently contains equivalents of the NIST DOM 1 test written for
    the JUnit test framework (http://www.junit.org) and JAXP 1.1 or 1.0 compatible parsers.
    The tests were written to allow easy migration to JavaScript using JSUnit
    (http://www.jsunit.net) and CPPUnit (http://www.xprogramming.org/software)
    To run the full set of tests, place domunit.jar, junit.jar and one of the following
    combinations of jars in the same directory or on the class path.
    xerces.jar
    xml4j.jar
    jaxp.jar and parser.jar (from Sun's JAXP 1.0 Reference Implementation)
    jaxp.jar and crimson.jar (from Sun's JAXP 1.1 Reference Implementation)
    and run:
    java -jar domunit.jar
    To test Oracle's XML Processor, place jaxp.jar from the JAXP 1.0 (not 1.1) Reference Implementation
    and xmlparserv2.jar in the domunit.jar directory and run:
    java -Djavax.xml.parsers.DocumentBuilderFactory=oracle.xml.jaxp.JXDocumentBuilderFactory
    -jar domunit.jar
    The following options can adjust the tests:
    -Dnet.sourceforge.xmlconf.domunit.isExpandEntityReferences=true
    -Dnet.sourceforge.xmlconf.domunit.isCoalescing=true
    -Dnet.sourceforge.xmlconf.domunit.acceptXMLDeclPI=true
    To build the project, use either the JBuilder 4 .jpx file or
    the Ant 1.2 build.xml file.
    Curt Arnold http://xmlconf.sourceforge.net
    [email protected]
    18 April 2001
    domunit - DOM testing on the xUnit frameworks
    Copyright (C) 2001, Curt Arnold
    This program is free software; you can redistribute it and/or
    modify it under the terms of the GNU General Public License
    as published by the Free Software Foundation; either version 2
    of the License, or (at your option) any later version.
    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    GNU General Public License for more details.
    You should have received a copy of the GNU General Public License
    along with this program; if not, write to the Free Software
    Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
    null

  • User not found?

    I have registered and i get User Not Found

    Thanks. Here it is:
    The one works:
    ldapsearch -h xxx.xxx.net -p 389 -D "cn=Directory Manager" -b "ou=people,o=xxx.net,dc=xxx,dc=net" -w xxxxxx "uid=song1234"
    uid=song1234, ou=people,o=xxx.net,dc=xxx,dc=net
    objectClass=top
    objectClass=person
    objectClass=organizationalPerson
    objectClass=inetorgperson
    objectClass=inetuser
    objectClass=ipuser
    objectClass=inetmailuser
    objectClass=inetlocalmailrecipient
    objectClass=nsmanagedperson
    objectClass=userpresenceprofile
    cn=abc
    sn=efg
    mailHost=xxx.xxx.net
    inetUserStatus=active
    mailUserStatus=active
    userPassword=#####################
    mail=[email protected]
    uid=song1234
    The one didn't work:
    ldapsearch -h xxx.xxx.net -p 389 -D "cn=Directory Manager" -b "ou=people,o=xxx.net,dc=xxx,dc=net" -w xxxxxx "uid=mongxun"
    uid=mongxun, ou=people,o=xxx.net,dc=xxx,dc=net
    objectClass=top
    objectClass=person
    objectClass=organizationalPerson
    objectClass=inetorgperson
    objectClass=inetuser
    objectClass=ipuser
    objectClass=inetmailuser
    objectClass=inetlocalmailrecipient
    objectClass=nsmanagedperson
    objectClass=userpresenceprofile
    cn=mong
    sn=xun
    uid=mongxun
    mail=[email protected]
    mailHost=xxx.xxx.net
    mailUserStatus=active
    mailDeliveryOption=mailbox
    inetUserStatus=active
    userPassword=#####################
    I really couldn't figure out the problem!!

  • FlexUnit 4 assert failures have "explosive" stack traces

    With FlexUnit 4 in Flash Builder 4 Plugin Beta, I created 1 suite with 1 class with 1 default failing test method. When I ran it, the assert failure had a call stack 60 methods high. Is this a bug?
    The stack trace has several "async" methods, e.g. applyExplosivelyAsync(). This seems strange because  I'm not using async at all. Is this intended behavior?
    Robert
    Test method Not yet implemented
           at flexunit.framework::Assert$/
    fail()[C:\Users\mlabriola\Documents\workspaces\net\digitalprimates\opensource\fluint\FlexU nit1Lib\src\flexunit\framework\Assert.as:370]
            at WidgetTest/testWidget()[C:\Users\robert.penner\Adobe Flash Builder
    Plug-in Beta 2\TestProject\src\WidgetTest.as:20]
            at Function/http://adobe.com/AS3/2006/builtin::apply()
            at flex.lang.reflect::Method/apply()[C:\Users\mlabriola\Documents\workspaces\net\digitalprim ates\opensource\flexunit\FlexUnit4\src\flex\lang\reflect\Method.as:124]
            at ReflectiveCallable/run()[C:\Users\mlabriola\Documents\workspaces\net\digitalprimates\open source\flexunit\FlexUnit4\src\org\flexunit\runners\model\FrameworkMethod.as:214]
            at org.flexunit.runners.model::FrameworkMethod/applyExplosivelyAsync()[C:\Users\mlabriola\Do cuments\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit\runn ers\model\FrameworkMethod.as:121]
            at org.flexunit.runners.model::FrameworkMethod/invokeExplosivelyAsync()[C:\Users\mlabriola\D ocuments\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit\run ners\model\FrameworkMethod.as:132]
            at org.flexunit.internals.runners.statements::InvokeMethod/evaluate()[C:\Users\mlabriola\Doc uments\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit\inter nals\runners\statements\InvokeMethod.as:52]
            at org.flexunit.internals.runners.statements::StackAndFrameManagement/evaluate()[C:\Users\ml abriola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\fle xunit\internals\runners\statements\StackAndFrameManagement.as:94]
            at org.flexunit.internals.runners.statements::StatementSequencer/executeStep()[C:\Users\mlab riola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexu nit\internals\runners\statements\StatementSequencer.as:62]
            at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[C:\Users\mlabriola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit 4\src\org\flexunit\internals\runners\statements\StatementSequencer.as:82]
            at org.flexunit.token::AsyncTestToken/sendResult()[C:\Users\mlabriola\Documents\workspaces\n et\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit\token\AsyncTestToken.as: 70]
            at org.flexunit.internals.runners.statements::AsyncStatementBase/sendComplete()[C:\Users\mla briola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flex unit\internals\runners\statements\AsyncStatementBase.as:44]
            at org.flexunit.internals.runners.statements::StatementSequencer/sendComplete()[C:\Users\mla briola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flex unit\internals\runners\statements\StatementSequencer.as:103]
            at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[C:\Users\mlabriola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit 4\src\org\flexunit\internals\runners\statements\StatementSequencer.as:86]
            at org.flexunit.internals.runners.statements::StatementSequencer/evaluate()[C:\Users\mlabrio la\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit \internals\runners\statements\StatementSequencer.as:68]
            at org.flexunit.internals.runners.statements::StatementSequencer/executeStep()[C:\Users\mlab riola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexu nit\internals\runners\statements\StatementSequencer.as:62]
            at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[C:\Users\mlabriola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit 4\src\org\flexunit\internals\runners\statements\StatementSequencer.as:82]
            at org.flexunit.internals.runners.statements::StatementSequencer/evaluate()[C:\Users\mlabrio la\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit \internals\runners\statements\StatementSequencer.as:68]
            at org.flexunit.runners::BlockFlexUnit4ClassRunner/runChild()[C:\Users\mlabriola\Documents\w orkspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit\runners\Block FlexUnit4ClassRunner.as:104]
            at org.flexunit.internals.runners::ChildRunnerSequencer/executeStep()[C:\Users\mlabriola\Doc uments\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit\inter nals\runners\ChildRunnerSequencer.as:49]
            at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[C:\Users\mlabriola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit 4\src\org\flexunit\internals\runners\statements\StatementSequencer.as:82]
            at org.flexunit.internals.runners.statements::StatementSequencer/evaluate()[C:\Users\mlabrio la\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit \internals\runners\statements\StatementSequencer.as:68]
            at org.flexunit.internals.runners.statements::StatementSequencer/executeStep()[C:\Users\mlab riola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexu nit\internals\runners\statements\StatementSequencer.as:62]
            at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[C:\Users\mlabriola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit 4\src\org\flexunit\internals\runners\statements\StatementSequencer.as:82]
            at org.flexunit.token::AsyncTestToken/sendResult()[C:\Users\mlabriola\Documents\workspaces\n et\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit\token\AsyncTestToken.as: 70]
            at org.flexunit.internals.runners.statements::AsyncStatementBase/sendComplete()[C:\Users\mla briola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flex unit\internals\runners\statements\AsyncStatementBase.as:44]
            at org.flexunit.internals.runners.statements::StatementSequencer/sendComplete()[C:\Users\mla briola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flex unit\internals\runners\statements\StatementSequencer.as:103]
            at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[C:\Users\mlabriola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit 4\src\org\flexunit\internals\runners\statements\StatementSequencer.as:86]
            at org.flexunit.internals.runners.statements::StatementSequencer/evaluate()[C:\Users\mlabrio la\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit \internals\runners\statements\StatementSequencer.as:68]
            at org.flexunit.internals.runners.statements::StatementSequencer/executeStep()[C:\Users\mlab riola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexu nit\internals\runners\statements\StatementSequencer.as:62]
            at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[C:\Users\mlabriola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit 4\src\org\flexunit\internals\runners\statements\StatementSequencer.as:82]
            at org.flexunit.internals.runners.statements::StatementSequencer/evaluate()[C:\Users\mlabrio la\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit \internals\runners\statements\StatementSequencer.as:68]
            at org.flexunit.runners::ParentRunner/run()[C:\Users\mlabriola\Documents\workspaces\net\digi talprimates\opensource\flexunit\FlexUnit4\src\org\flexunit\runners\ParentRunner.as:315]
            at org.flexunit.runners::Suite/runChild()[C:\Users\mlabriola\Documents\workspaces\net\digita lprimates\opensource\flexunit\FlexUnit4\src\org\flexunit\runners\Suite.as:59]
            at org.flexunit.internals.runners::ChildRunnerSequencer/executeStep()[C:\Users\mlabriola\Doc uments\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit\inter nals\runners\ChildRunnerSequencer.as:49]
            at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[C:\Users\mlabriola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit 4\src\org\flexunit\internals\runners\statements\StatementSequencer.as:82]
            at org.flexunit.internals.runners.statements::StatementSequencer/evaluate()[C:\Users\mlabrio la\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit \internals\runners\statements\StatementSequencer.as:68]
            at org.flexunit.internals.runners.statements::StatementSequencer/executeStep()[C:\Users\mlab riola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexu nit\internals\runners\statements\StatementSequencer.as:62]
            at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[C:\Users\mlabriola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit 4\src\org\flexunit\internals\runners\statements\StatementSequencer.as:82]
            at org.flexunit.token::AsyncTestToken/sendResult()[C:\Users\mlabriola\Documents\workspaces\n et\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit\token\AsyncTestToken.as: 70]
            at org.flexunit.internals.runners.statements::AsyncStatementBase/sendComplete()[C:\Users\mla briola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flex unit\internals\runners\statements\AsyncStatementBase.as:44]
            at org.flexunit.internals.runners.statements::StatementSequencer/sendComplete()[C:\Users\mla briola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flex unit\internals\runners\statements\StatementSequencer.as:103]
            at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[C:\Users\mlabriola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit 4\src\org\flexunit\internals\runners\statements\StatementSequencer.as:86]
            at org.flexunit.internals.runners.statements::StatementSequencer/evaluate()[C:\Users\mlabrio la\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit \internals\runners\statements\StatementSequencer.as:68]
            at org.flexunit.internals.runners.statements::StatementSequencer/executeStep()[C:\Users\mlab riola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexu nit\internals\runners\statements\StatementSequencer.as:62]
            at org.flexunit.internals.runners.statements::StatementSequencer/handleChildExecuteComplete( )[C:\Users\mlabriola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit 4\src\org\flexunit\internals\runners\statements\StatementSequencer.as:82]
            at org.flexunit.internals.runners.statements::StatementSequencer/evaluate()[C:\Users\mlabrio la\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit \internals\runners\statements\StatementSequencer.as:68]
            at org.flexunit.runners::ParentRunner/run()[C:\Users\mlabriola\Documents\workspaces\net\digi talprimates\opensource\flexunit\FlexUnit4\src\org\flexunit\runners\ParentRunner.as:315]
            at org.flexunit.runner::FlexUnitCore/beginRunnerExecution()[C:\Users\mlabriola\Documents\wor kspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit\runner\FlexUnit Core.as:177]
            at org.flexunit.token::AsyncListenersToken/sendReady()[C:\Users\mlabriola\Documents\workspac es\net\digitalprimates\opensource\flexunit\FlexUnit4\src\org\flexunit\token\AsyncListeners Token.as:59]
            at org.flexunit.runner.notification.async::AsyncListenerWatcher/sendReadyNotification()[C:\U sers\mlabriola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\ org\flexunit\runner\notification\async\AsyncListenerWatcher.as:87]
            at org.flexunit.runner.notification.async::AsyncListenerWatcher/handleListenerReady()[C:\Use rs\mlabriola\Documents\workspaces\net\digitalprimates\opensource\flexunit\FlexUnit4\src\or g\flexunit\runner\notification\async\AsyncListenerWatcher.as:97]
            at flash.events::EventDispatcher/dispatchEventFunction()
            at flash.events::EventDispatcher/dispatchEvent()
            at flexunit.flexui::FlexUnit4TestRunner/handleConnect()[C:\work\flex\ide_builder\com.adobe.f lexbuilder.flexunit\flexunitframework\src\flexunit\flexui\FlexUnit4TestRunner.as:296]
            at flash.events::EventDispatcher/dispatchEventFunction()
            at flash.events::EventDispatcher/dispatchEvent()
            at flash.net::XMLSocket/reflectEvent()

    Not a bug and fully expected behavior.
    FlexUnit 4 is really just a collection of runners that can handle just about anything that is thrown at it as well as handle any pluggable runners that others write. The level of extensibility comes with some complexity. So, by the time that single method of yours is executed, there are actually probably a hundreds methods in the framework for getting everything setup, inspected and ready to go.
    The stacktrace always looks up the stack from your failure to the last point where a particular chunk of code execution began, so the 60 is basically just that number of methods. There isn't a whole lot that can be done about it save for eventually provinding filtering to eliminate showing some of our stuff and making the track more legible.
    Regarding the async thing, your method isn't async but FlexUnit4 is. Inside of the Flash Player we are operating on frames. We don't have the luxury of threads and the like that Java has, so we have to handle the possibility that something might be async on a much deeper level. We also do something called green threading where we actually watch how much time we take in execution. Once we have taken 90% ish of the time available in a given frame, we wait until the next one before we begin executing again. This allows us to run long and compelx test suites without getting a timeout from the flash player (which happens if any single frame takes longer than 15 seconds to execute). So, even though your method isn't doing anything async, all of these other pieces have to account for the chance that something will be. Hence the reason that you see async pieces in the stack trace.
    Hope that helps,
    Mike

Maybe you are looking for

  • Win2003 SP2 VM won't boot to safe mode

    I have a Windows Server 2003 SP2 VM set up in Hyper-V on my Windows Server 2008 R2 server.  The VM was created as an export from AppAssure 5 export to Hyper-V Virtual Standby.  This particular server won't complete the boot but "sits" at the Windows

  • Dynamic form... field names and values...

    Boy-Howdy. I wish I had the opportunity to stop by this forum and hang out at a time when I am not having issue, but, alas... I appreciate the brain power of the great minds that populate this forum. I have an issue: I think I am close on this but ca

  • I was asked to power cycle the iphone. What is power cycle?

    I was asked to power cycle the iphone. What does it mean to power cycle? How do you do it?

  • Best practice for updating a list that is data bound

    Hi All, I have a List component and the data is coming in from a bindable ArrayCollection. When I make changes to the data in the bindable ArrayCollection, the change is not being reflected in the list. I notice that if I resize the browser the compo

  • Error in UTL_SMTP.rcpt command

    Hi, I am using UTL_SMTP.rcpt commnd to send mail to multiple user but its getting error when v_email_id_1 string length exceeds 500 . UTL_SMTP.rcpt(v_l_mail_conn, v_email_id_1); v_l_mail_conn := UTL_SMTP.connection; v_email_id_1:= is a varchar2 field