Test GUI Exception----help!!!!!!!!!!!!!!!!

I run the junit test case from dos after typing
"java junit.swingui.TestRunner MoneyTest"
Before running the test case in the junit sample fold, i set the Classpath which include one fold named "test", then i copy the sample of MoneyTest into this fold to try Junit, but the result is :
GUI appears and i also can use the Test Selector search all the Test Cases from the fold "test" ,but in Dos window shows following Exception: (GUI of course can not run)
Exception in thread "main" java.lang.NoClassDefFoundError: MoneyTest (wrong name
: junit/samples/money/MoneyTest)
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.lang.ClassLoader.defineClass(Unknown Source)
at junit.runner.TestCaseClassLoader.loadClass(TestCaseClassLoader.java:1
04)
at junit.runner.ReloadingTestSuiteLoader.load(ReloadingTestSuiteLoader.j
ava:9)
at junit.runner.BaseTestRunner.loadSuiteClass(BaseTestRunner.java:193)
at junit.runner.BaseTestRunner.getTest(BaseTestRunner.java:86)
at junit.swingui.TestRunner.runSuite(TestRunner.java:591)
at junit.swingui.TestRunner.start(TestRunner.java:708)
at junit.swingui.TestRunner.main(TestRunner.java:52)
Exception in thread "AWT-EventQueue-0" java.lang.NoClassDefFoundError: MoneyTest
(wrong name: junit/samples/money/MoneyTest)
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.lang.ClassLoader.defineClass(Unknown Source)
at junit.runner.TestCaseClassLoader.loadClass(TestCaseClassLoader.java:1
04)
at junit.runner.ReloadingTestSuiteLoader.load(ReloadingTestSuiteLoader.j
ava:9)
at junit.runner.BaseTestRunner.loadSuiteClass(BaseTestRunner.java:193)
at junit.runner.BaseTestRunner.getTest(BaseTestRunner.java:86)
at junit.swingui.TestRunner.runSuite(TestRunner.java:591)
at junit.swingui.TestRunner$9.actionPerformed(TestRunner.java:283)
at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Sour
ce)
at java.awt.Component.processMouseEvent(Unknown Source)
at javax.swing.JComponent.processMouseEvent(Unknown Source)
at java.awt.Component.processEvent(Unknown Source)
at java.awt.Container.processEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Window.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
I dont know where problems happened??? Thank you for any help!!!!
Alonso

I run the junit test case from dos after typing
"java junit.swingui.TestRunner MoneyTest"
Exception in thread "main"
java.lang.NoClassDefFoundError: MoneyTest (wrong
name
: junit/samples/money/MoneyTest)
I dont know where problems happened??? Thank you for
any help!!!!See the part in the exception about where is says "wrong name"?
It means you used the wrong name (surprising how that works.)
See the section after it where is says "junit/samples/money/MoneyTest"?
That tells you that it couldn't find the name that you gave it, but that it did find a name called junit.samples.money.MoneyTest.
It is up to you to figure out if you really wanted to use junit.samples.money.MoneyTest or if you made a mistake in something else.

Similar Messages

  • TAKE HOME TEST i need help with

    Chapter 11 ? Arrays Continued Test
    CAN ANY1 HELP ME ANSWER THIS??
    1. A hair styling salon provides many services, The HairSalon class contains a String field to hold the type of service, a double to hold the price for that service, and a double to hold the time that it takes to perform the service in hours.minutes (example: 1.5 hours is one and a half hours).
    public class HairSalon
    private String service;
    private double price;
    private double time;
    pub1ic HairSalon (.......
    /********* the constructor to be completed in Part a
    public String getservice ( ) (
    To be completed in part a
    public double getprice( )
    To be completed in part a
    public double getTime ( )
    To be completed in part a
    public int compareTo(0bject other)
    To be completed in part b
    public boolean equals (Object other)
    To be completed in part c
    Part a: (10 points) Write a constructor that requires arguments for all three data fields, and three get methods that each return one of the data field's value.
    public HairSalon(
    public String getService(
    public double getPrice( )
    public String getTime( )
    Part b. (5 points) Write the method compareTo which compares the rate for the service (dollars per hour). public int compareTo(0bject other)
    Part c. (5 points) Write the method equals which compares the rate for the service (dollars per hour).
    public boolean equals(0bject other)
    }

    Part a)
    package cruft;
    * @author salman
    class HairSalon{
    private String service;
    private double price;
    private double time;
      public HairSalon(String service, double price, double time)
          this.service = service;
          this.price = price;
          this.time = time;
      public String getService()
        return service;
      public double getPrice()
        return price;
    public String getTime()
        return time;
    }

  • Idoc Testing! Need help!

    Hi!
       (Please give answers specific to my question & pls read below)
         i want to test idoc outbound as well as inbound.
      First Consider inbound,
       I ve read previous posted threads it was mentioned  goto>we19> give idoc no
      I want to know <b>what is idoc no how we get idoc no for the idoc.
    </b>
    Then i know the steps...
      Now Outbound,
      How to test outbound idoc -- i want to know how my posting program has correctly generated idoc to ale layer.
      I want this in complete detail.
       Thanks!
       Rahul.

    Hi Rahul,
    <b>idoc structure</b>
    http://www.sapbrainsonline.com/ARTICLES/TECHNICAL/idoc/SAP_IDOC_structure_introduction.html
    <b>What is Idoc?</b>
    <b>I give overview of IDoc terminology and how IDocs work in an enterprise will clarify the process</b>
    SAP’s presence in the IT world is justified by a central premise: It turns a company’s many individual systems into one, big supersystem. More than a linking together of applications, SAP’s implementation causes a redirection of the flow of information through a company and its partner companies that enhances the potential of its business functions.
    This flow of information is enabled by a core element in SAP technology: the Intermediate Document, or IDoc. Technically, the IDoc is an example of Electronic Data Interchange (EDI). Unlike conventional EDI, IDocs are not based on a descriptive language.
    The IDoc concept borrows the best features of EDI and combines them with the best features of conventional transaction file formats. The result is a lean data transport mechanism that is the engine of SAP data flow, tying together applications, databases, companies, and networks. Here is a look at the makeup of IDocs within the application architecture.
    Form and content: IDoc terminology
    As is often the case with proprietary technologies, SAP assigns specific, object-oriented meanings to familiar terms. When referring to IDocs, the term document refers to a set of data comprising a functional group of records with a business identity. (For example, all the data in a purchase order, or all the profile information of a supplier in a supplier master record.)
    A message refers to the contents of a specific implementation of an IDoc; it’s a logical reference. This differs from a reference to the IDoc itself, which specifies the message’s physical representation. Think of it this way: If you’re watching a parade pass by, the mayor waving to the crowd from his limousine is the message, and the mayor’s limousine (which is specific to the mayor) is the IDoc. You’re building a logical object, and the IDoc is both its container and the vehicle that moves it.
    The IDoc control record
    Each IDoc has a single control record, always the first record in the set. The structure of this record describes the content of the data records that will follow and provides administrative information, such as the IDoc’s functional category (Message Type/IDoc Type), as well as its origin (Sender) and destination (Receiver) as in conventional EDI (see Figure A).
    Figure A
    IDOC number  Sender  Receiver  Port  Message type  IDoc type 
    1234567890    R3NYC  R3LA     FILE  INVOICES       INVOICE01 
    This “cover slip” format informs the receiving system of the IDoc’s purpose, and the receiving system uses it to determine the correct processing algorithm for handling the arriving IDoc.
    Data records
    The data records following the control record are structured alike, including two sections: a segment information section and a data section.
    In the first part of a data record, the segment information section describes the structure of the data that follows, for the benefit of the IDoc processor. There is a segment name (like an EDI segment identifier) that corresponds to a data dictionary structure to which the IDoc processor has access. The remaining information is useful for foreign systems, such as a partner company’s Oracle system, which has no such data dictionary.
    The second part of the record is the data itself, a storage area of 1,000 characters.
    Status records
    If you’ve ever ordered a package from a faraway location and tracked its progress using the Internet-based tracking utilities now provided by most major parcel carriers, you’re familiar with the list of stops and transfer points through which a package passes on its way to you.
    This collection of records is exactly what you’ll see in an IDoc that has begun its work. Following the data records in an IDoc, status records accumulate as an IDoc makes its way from one point in a process to another.
    Typically, an IDoc will acquire several of these records as its does its job. They are simple records, consisting of a status code (there are more than 70 codes, covering a broad range of conditions and errors), a date/time stamp, and some additional status information fields for system audit purposes. In addition, as errors occur in the processing of an IDoc, status records (see Figure B) are used to record these errors and the date/time of their occurrence.
    Figure B
    (Display Status Record) 
    IDoc number  0000000000123456 
    Direction  1 Outbound 
    Status information          
         38 IDoc archived       
    (additional descriptive text)       
    Log time       
        Date  6-30-02    
        Time  14:35:21    
    Portion of IDoc status display 
    IDoc Base
    IDocs, as data formatting tools, enable the easy sharing of data between databases and applications within a company as well as being an efficient data courier between companies. Typically in SAP, a database of IDoc definitions exists, to which any application may have access.
    This “IDoc Base” gives all the applications and processes in your company domain the capacity to send, receive, and process a document in a contextually appropriate way, without doing anything to the data. For example, a purchase order IDoc can filter through every process it touches, passing from system to system, accumulating status records to track its progress.
    Every department using the data can use it appropriately without any cumbersome intermediate processes, because each department draws its key to interpreting the IDoc from the same source.
    Multiple messages
    One cumbersome feature of conventional EDI is the embedding of more than one functional record type in a document. The unwieldy X-12 888 Item Maintenance transaction set is an example: It purports to handle so many different configurations of product master data that it is horrifically difficult to integrate into an existing system.
    IDocs, on the other hand, handle multiple messages with ease. Given the centralized IDoc interpretation that SAP provides to all its parts, it’s no problem to define an IDoc that will contain more than one message, that is, more than one data record type.
    A customer master IDoc, for example, may contain customer profile information records for a customer with many locations. But it may also contain location-specific pricing information records for that customer in the same document. This is an incredibly efficient way of bundling related records, particularly when passing large amounts of complex information from system to system (see Figure C).
    Figure C
    CONTROL RECORD 
    DATA RECORD - CUST PROFILE LOC #1 
    DATA RECORD - CUST PROFILE LOC #2 
    DATA RECORD - CUST PROFILE LOC #3 
    DATA RECORD - CUST DISCOUNT STRUCTURE LOC #1 
    DATA RECORD - CUST DISCOUNT STRUCTURE LOC #2 
    DATA RECORD - CUST DISCOUNT STRUCTURE LOC #3 
    STATUS RECORD 
    STATUS RECORD 
    STATUS RECORD 
    Records in a multiple-message IDoc
    Final thought
    There is no mastering SAP without mastering its workhorse, the IDoc. ERP environments utilizing SAP and similar platforms are made necessary in the first place by the increasing demands of ever more integrated business relationships. IDoc technology addresses this trend with a simple but powerful design philosophy: Data is no longer something to be stored; it’s something to be moved.
    <b>And</b>
    These links give u complete details abt idocs testing
    Test Tool
    http://help.sap.com/saphelp_erp2004/helpdata/en/dc/6b80f643d711d1893e0000e8323c4f/content.htm
    Status Monitor for ALE Messages
    http://help.sap.com/saphelp_nw04/helpdata/en/d4/0d67e4d85511d2a6080060087832f8/content.htm
    Regards ,
    Kumar.

  • Junit - test for exception problem

    I'm trying to test if an exception is being thrown (when one is expected)
    I get this error (when I shouldn't):
    java.lang.AssertionError: Expected exception: exception.OutOfRangeException
    The method being tested:
    public void setScore ( int score ) throws exception.OutOfRangeException
      if ( ( score < 0 ) || ( score > 100 ) ) {
          throw new exception.OutOfRangeException( "Score invalid: " + score );
      else {
          this.score = score
    }The test method:
    @Test(expected=exception.OutOfRangeException.class)
    public void testScoreOutOfRangeException() {
        try {
            record.setScore (-1);
        catch ( OutOfRangeException e ) {
             // do nothing because we expected it
    }What I am doing wrong?

    Yes, it does compile.
    You are catching the exception.
    junit expects to see the exception itself. You arecatching it so it doesn't see it.
    I understand what you are saying. I originally didn't
    type in the try/catch in the test method. But if I
    remove the try/catch I get this error:
    Unhandled exception type OutOfRangeExceptionI don't know much about Junit 4, but my preferred way of testing exceptions is to surround them in a try/catch as you have but to call Assert.fail() at the end of the try block
    public void testScoreOutOfRangeException() {
        try {
            record.setScore (-1);
            fail("should have thrown an OutOfRangeException)";
        catch ( OutOfRangeException e ) {
             // do nothing because we expected it
    }You'll have to look at Teh Docs for JUnit4 to see how to force a fail, though

  • 4S w/8.1. All alerts, phone, message etc stopped working. Ckd settings can't find answer. Ckd sounds on settings all test good. Help.

    4S w/8.1. All alerts, phone, message etc stopped working. Ckd settings can’t find answer. Ckd sounds on settings all test good. Help.

    settings - do not disturb - off
    use the side control and make sure the switch is up for ringer and not on vibrate.

  • Gui optionpane help!!

    hi, i need some help with the optionpane component in java gui, in the option pane i need to list the strings in the array called test ( i have labelled the place where they need to go as the word "something"), can anyone assist?
    try {
          // Create a FileReader and then wrap it with BufferedReader.
          FileReader file_reader = new FileReader (file);
          BufferedReader buf_reader = new BufferedReader (file_reader);
          do {
             String line = buf_reader.readLine ();
             if (line == null) break;
          if(line.startsWith("busl")){String[] test = line.split(" ");
          //System.out.println(test);
          } while(true);
          Object response = JOptionPane.showInputDialog(null,
                "Select a bus line",
                "Bus line", JOptionPane.QUESTION_MESSAGE,
                null, new String[] { "something", "something",
                    "something", "something", "something" },
                "something");
           catch (IOException e) {
            System.out.println ("IO exception =" + e );
           }

    Swing forum: http://forum.java.sun.com/forum.jspa?forumID=57

  • No Receivers Found Exception -- Help Requested

    Hi All,
    I am getting "No Receivers Found Exception" in a BPM I am executing in which I used a receiver determination step.
    I did go thru other forum thread by Tirumal,
    "No Receiver Specified" , BPM Error
    I do not have any objects in the change list either in Repository or Directory.
    I did not get any errors or warnings when I checked the Integration Process designed.
    I did refresh cache with return code 0 and I did remove the existing Integration Process reference in Directory and recreated the same.
    I tested the interface with the directory test tool and no errors resulted.
    I ran out of options to solve this problem, any help for the same is greatly appreciated.
    Thanks,
    -Padmaja

    Hi Padmaja,
    Try doing a cache refresh.
    cheers,
    Prashanth
    P.S Please mark helpful answers

  • JDBC connect to Oracle, IO exception, Help!

    I am trying to connect to Oracle server via JDBC, but encountered IO exception problem, could anyone provide me any help? code is as follows:
    String url ="jdbc:oracle:thin:@IP:1521:oracleSID"
    Class.forName ("oracle.jdbc.driver.OracleDriver");
    con = DriverManager.getConnection (url,usr,pwd);
    the exception info is:
    java.sql.SQLException:IOException: The network adapter could not establish the connection
    require for help to solve this problem, many thanks!

    import java.io.*;
    import java.sql.*;
    import java.text.*;
    import oracle.jdbc.driver.*;
    public class viewtable
         Connection con;
         Statement st;
         public viewtable (String args[]) throws ClassNotFoundException,FileNotFoundException,IOException,SQLException
         url="jdbc:oracle:thin:system/manager@IP:1521:SID";
         Class.forName ("oracle.jdbc.driver.OracleDriver");
         try
         con=DriverManager.getConnection(url);
              st = con.createStatement ();
              doexample ();
              st.close ();
              con.close ();
         }catch(SQLException e)
              System.err.println(e.getMessage());
         public void doexample () throws SQLException
         ResultSet rs = st.executeQuery("select * from sales");
              if(rs!=null) {
              while(rs.next())
                   int a = rs.getInt("no");                    System.out.println("NO = "+a);
              rs.close();
         public static void main (String args[])
              System.out.println ("Oracle Exercise 1 \n");
              try
                   viewtable test = new viewtable(args);
              } catch (Exception ex)
                   System.err.println ("Exception caught.\n"+ex);
                   ex.printStackTrace ();
    the above is the full code, please check the problem....many thanks

  • GUI Exception while installing IdM 6.0 in non GUI mode

    I am trying to upgrade IdM from 5.5 to 6.0 using command "./install -nodisplay" on a unix console.
    bash-prompt$ ./install -nodisplay
    The installation goes through fine with pre process and installation. However, during the post-process it throws an exception when trying to invoke a GUI interface. The exception is at the bottom of this message. It seems that the "nodisplay" option doesn't seem to work and using a remote Xwindows session is not an option due to business and security reasons.
    Does anyone know if there is a way around this where I can run the upgrade without ever invoking a GUI? Please let me know. Any direction would be quite helpful at this point.
    Thank you
    A
    Exception duirng installation post process
    2006-xx-xxT17:13:30.361-0400 ========= Importing '/...../sample/update.xml'
    2006-xx-xxT17:13:30.807-0400 Caught exception: java.lang.NoClassDefFoundError
    2006-xx-xxT17:13:30.812-0400 java.lang.NoClassDefFoundError
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:141)
    at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:62)
    at java.awt.Font.initializeFont(Font.java:308)
    at java.awt.Font.<init>(Font.java:344)
    at javax.swing.plaf.metal.DefaultMetalTheme$FontDelegate.getFont(DefaultMetalTheme.java:195)
    at javax.swing.plaf.metal.DefaultMetalTheme.getFont(DefaultMetalTheme.java:153)
    at javax.swing.plaf.metal.DefaultMetalTheme.getUserTextFont(DefaultMetalTheme.java:137)
    at javax.swing.plaf.metal.MetalLookAndFeel$FontActiveValue.createValue(MetalLookAndFeel.java:1405)
    at javax.swing.UIDefaults.getFromHashtable(UIDefaults.java:199)
    at javax.swing.UIDefaults.get(UIDefaults.java:129)
    at javax.swing.MultiUIDefaults.get(MultiUIDefaults.java:44)
    at javax.swing.UIDefaults.getFont(UIDefaults.java:349)
    at javax.swing.UIManager.getFont(UIManager.java:491)
    at javax.swing.plaf.basic.BasicTextUI.installDefaults(BasicTextUI.java:216)
    at javax.swing.plaf.basic.BasicTextUI.installUI(BasicTextUI.java:674)
    at javax.swing.JComponent.setUI(JComponent.java:449)
    at javax.swing.text.JTextComponent.setUI(JTextComponent.java:287)
    at javax.swing.text.JTextComponent.updateUI(JTextComponent.java:297)
    at javax.swing.text.JTextComponent.<init>(JTextComponent.java:271)
    at javax.swing.JTextArea.<init>(JTextArea.java:186)
    at javax.swing.JTextArea.<init>(JTextArea.java:122)
    at com.waveset.install.UpgradeProcessProgressPanel.getTextArea(UpgradeProcessProgressPanel.java:196)
    at com.waveset.install.ProgressPanelAdapter.getWriter(ProgressPanelAdapter.java:58)
    at com.waveset.install.UpgradePostProcess.importUpdateXml(UpgradePostProcess.java:737)
    at com.waveset.install.UpgradePostProcess.doUpgrade(UpgradePostProcess.java:526)
    at com.waveset.install.UpgradePostProcess.install(UpgradePostProcess.java:490)
    at com.waveset.install.UpgradeProcessProgressPanel.run(UpgradeProcessProgressPanel.java:333)
    at com.waveset.install.UpgradeProcessProgressPanel.consoleInteraction(UpgradeProcessProgressPanel.java:149)
    at com.waveset.install.UpgradePostProcessProgressPanel.consoleInteraction(UpgradePostProcessProgressPanel.java:48)
    at com.sun.wizards.core.IteratorLayout.cliConsoleInteraction(IteratorLayout.java:806)
    at com.sun.wizards.core.AutonextController.displayPanel(AutonextController.java:561)
    at com.sun.wizards.core.AutonextController.setCurrentPanel(AutonextController.java:485)
    at com.sun.wizards.core.IteratorLayout.setCurrentLeaf(IteratorLayout.java:639)
    at com.sun.wizards.core.IteratorLayout.next(IteratorLayout.java:1007)
    at com.sun.wizards.core.WizardTreeManager.actualNextButtonPressed(WizardTreeManager.java:1308)
    at com.sun.wizards.core.WizardTreeManager.nextButtonPressed(WizardTreeManager.java:1341)
    at com.sun.setup.panels.common.ProgressPanel.sequenceComplete(ProgressPanel.java:540)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:324)
    at com.sun.wizards.core.WizardTreeManager.callObjectMethod(WizardTreeManager.java:2377)
    at com.sun.wizards.core.WizardTreeManager.callClientObjectMethod(WizardTreeManager.java:2209)
    at sun.reflect.GeneratedMethodAccessor7.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:324)
    at com.sun.wizards.core.ArchiveReader.callObjectMethod(ArchiveReader.java:1404)
    at com.sun.wizards.core.GenericWizardState.callClientObjectMethod(GenericWizardState.java:2827)
    at com.sun.wizards.core.Sequence.callSequenceCompleteMethod(Sequence.java:272)
    at com.sun.wizards.core.Sequence.perform(Sequence.java:364)
    at com.sun.wizards.core.SequenceManager.run(SequenceManager.java:226)
    at java.lang.Thread.run(Thread.java:534)

    [My first ever post...]
    I came across much the same problem upgrading from v5.0. In my case the cause was a non-default Configurator password, and then the inability to provide the actual password because the pop-up XWindow has no 'okay' button.
    From memory I encountered the class error you are seeing when I unset my DISPLAY env var (this is on a Solaris + AS7 install).
    The fix was to restore the default password; nothing else would work. But of course if you've upgraded your database already, then you don't really have the option of using the IdM v5.0/v5.5 install to edit Configurator directly.
    For me I found that I could use the v6.0 bin/lh console, logging in as Configurator via the command line and then importing an exchange file with Configurator set to the default password value (I obtained this string from an old dev machine). Of course bin/lh console assumes the default Configurator password as well, but this time unsetting DISPLAY allowed me to just enter the actual value from the command line.
    Laborious process but it worked. I then just ran sample/update.xml and everything was back on track...

  • Test Controller exception: No such host is know

    I'm getting following errors on the test controller machine, when I'm trying to run CodedUI tests remotely:
    (QTController.exe, PID 3032, Thread 12) ControllerDeployment.DoDeployment: System.Net.Sockets.SocketException (0x80004005): No such host is known
    During controller and agent configuration no errors came up. And when I go to Manage test controller dialog in Visual Studio I can see all the agents active. But when I try to execute any CodedUI test remotely it's hanging forever.
    Not sure if it's connected with the fact that I've upgraded client/controller/agents to 2012 versions recently, but I've started seeing the problem only after this upgrade.

    Hello Anton,
    Glad to receive your reply.
    Have you try the suggestions step by step provided in this link (http://social.msdn.microsoft.com/Forums/en-US/vststest/thread/df043823-ffcf-46a4-9e47-1c4b8854ca13)?
    I think that those steps are very useful which you can try them.
    1.Use Visual Studio or Microsoft Test Manager (see Tools section above) to view Controller status.
    2.If you can’t connect to Controller, make sure that Controller service is running:
       On Controller machine (you can also do that remotely) re/start controller service (see Tools section in Appendix).
    3. (if you still can’t connect) On Controller machine make sure that it can accept incoming connections through Firewall:
    Open port 6901 (or create exception for the service program/executable).
    Add Firewall Exception for File and Printer Sharing.
    4. (if you still can’t connect) make sure that the user you run the Client under has permissions to connect to Controller:
    On Controller machine, add Client user to the TeamTestControllerAdmins local group.
    5. (if you still can’t connect) On Client machine make sure that Firewall is not blocking incoming and outgoing connections:
    Make sure that there is Firewall exception for Client program (devenv.exe, mstest.exe, mlm.exe) so that it can accept incoming connections.
    Make sure that Firewall is not blocking outgoing connections.
    6. If you still can’t connect, you can try to re-configure the test controller and test agent.
    7.If you still can’t connect, restart Controller service
    In addition, I would like to know if you have VS2010 and VS2012 on the same machine. If yes, maybe it can cause some unexpected issue. I suggest that you can install the VS2010 to check
    the result.
    Hope you can update the result once you have tried the steps
    Best regards,
    Amanda Zhu [MSFT]
    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.

  • Invalid Cursor state Exception  -  Help required

    Hi,
    I'm having a web page(JSP), which is making use of 3 ResultSet objects. Using the first two, i'll populate two different Drop down list, with values from database(Access) while loading the page for first time.
    Now if the user select any value from any (or both) of drop down list and clicks submit, i need to display all values in database, meeting the criteria from first & second drop down list. For this selection, i'm using the third ResultSet variable. While executing the query, i'm sure that 3rd ResultSet is returning some value. But when i try to retrieve the value to a string variable, i'm getting the Invalid cursor state exception.
    Throughout the page, i haven't closed any of the ResultSet. When i closed the first and second ResultSets in the third function(where 3rd ResultSet is used), i'm not getting any value. Its returning like ResultSet closed.
    Please help me to get this solved. It's very urgent because without this, i cannot proceed further. Please share your ideas.
    Thanks in advace for your valuable help

    If you open a new resultset within the same statement, all previously opened will be closed.
    Read the API docs, luke.

  • Creating GUI based Help File!!!

    Can anyone point me to a resource where I can find information for creating Help for a GUI based application? I know that javadoc can create API specification for standalone programs but I like something for GUI based application like the one found on MS Word under Help menu.
    Need help plz.
    --DM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

    If anyone is trying to find out how DM777 implemented help. I would guess that he found JavaHelp.
    Here's a search to get you started
    http://onesearch.sun.com/search/developers/index.jsp?and=javahelp&nh=10&phr=&qt=&not=&field=&since=&col=javadoc&col=javatecharticles&col=javatutorials&col=devarchive&col=devall&rf=0&Search.x=0&Search.y=0

  • Mapping test throughs exception for UDF that does'nt exist anymore

    Hello everybody,
    my mapping test throughs an exception for a UDF that I deleted?
    Any ideas?
    Regards Mario

    Hi Mario,
       Sometimes XI Mapping test may throw an Error if any of the other UDF is having errors.
       So please do the following and check whether you are able to run mapping test.
       1. Check all the UDF for any syntax errors/import stmt error etc.
       2. goto Edit mode and do some dummy changes (Like changing UDF Description etc) and activate and check again.
    Regards,
    Ananth

  • Test exact exception messages in java SE with locale for program handling

    My problem is test the exact exceptions returned by JAVA Standard Engine for program handling.
    I work in systems usually set to "Italian Locale" and the result is different in different platforms.
    When I work in MSWindows with Java almost messages are in English but not all, for example IOException "Cannot assign requested address" in the Italian Locale is "Indirizzo richiesto non valido nel proprio contesto" but other messages like "Socket Closed" remain "Socket Closed".
    Catch the exact exception through description is not a good idea but I don't found other way for Java SE native exceptions!
    In Solaris I try to set English LANG environment in the user context and it works.
    In MS Windows I try to set the definition in start java with:
    *"java -Duser.language=en -Duser.region=US"*
    and in the code I try to add the statement:
    Locale.setDefault(Locale.US);
    but without results.
    Is there anybody that has the same problem?
    Is there a better way to catch the exact type of Java SE exceptions ?
    My test Environments:_
    Solaris 10 jdk 1.6.0.02
    MS Windows 2000 jdk 1.6.0.02
    MS Windows XP jdk1.6.0.02 and 1.5.0.12
    Fragment program example for additional explanation:_
    try {
    } catch (IOException ex) {
    if (ex.getMessage().equals("Socket Closed"))
    System.out.println("Ok socket closed exception catched");
    if (ex.getMessage().equals("Cannot assign requested address"))
    System.out.println("Ok assign requested address exception catched");
    }

    My problem is test the exact exceptions returned by JAVA Standard Engine for program handling.
    I work in systems usually set to "Italian Locale" and the result is different in different platforms.
    When I work in MSWindows with Java almost messages are in English but not all, for example IOException "Cannot assign requested address" in the Italian Locale is "Indirizzo richiesto non valido nel proprio contesto" but other messages like "Socket Closed" remain "Socket Closed".
    Catch the exact exception through description is not a good idea but I don't found other way for Java SE native exceptions!
    In Solaris I try to set English LANG environment in the user context and it works.
    In MS Windows I try to set the definition in start java with:
    *"java -Duser.language=en -Duser.region=US"*
    and in the code I try to add the statement:
    Locale.setDefault(Locale.US);
    but without results.
    Is there anybody that has the same problem?
    Is there a better way to catch the exact type of Java SE exceptions ?
    My test Environments:_
    Solaris 10 jdk 1.6.0.02
    MS Windows 2000 jdk 1.6.0.02
    MS Windows XP jdk1.6.0.02 and 1.5.0.12
    Fragment program example for additional explanation:_
    try {
    } catch (IOException ex) {
    if (ex.getMessage().equals("Socket Closed"))
    System.out.println("Ok socket closed exception catched");
    if (ex.getMessage().equals("Cannot assign requested address"))
    System.out.println("Ok assign requested address exception catched");
    }

  • Catching an exception (help)!!!

    Hi everyone, the problem i have is when the user enters a number that is out of bounds (higher or lower than the excepted values it should prompt the program to write to the screen "out of range, try again" or something along those lines.
    However, it instead just prints "error - program terminated" which is the message that should be printed when there is a different problem within the program.
    Can anyone help me get the program to print the correct messages, you can see what i mean from the code:
    import java.io.*;
    import java.util.ArrayList;
    public class FlatCost { 
        ArrayList floors = new ArrayList();
        public FlatCost(String filename)  {   
            try    {     
                readDataFromFile(filename);
                BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
                int floor;
                int rooms;     
                String another = "y";     
                while(another.equalsIgnoreCase("y"))      {
                    System.out.print("\nEnter floor number (0 for ground): ");
                    floor = Integer.parseInt(in.readLine());      
                    if(floor < 0 || floor > floors.size())        {
                    System.out.println("floor out of range, try again");       
                else        {
                    System.out.print("\nEnter no. rooms: ");
                    rooms = Integer.parseInt(in.readLine());         
                    if(rooms < 0 || rooms > ((String[])floors.get(floor)).length)          {
                        System.out.println("rooms out of range, try again");         
                    else          {
                        System.out.println("\nThe cost of a "+rooms+"-room flat on floor "+floor+" is "+                                  
                        ((String[])floors.get(floor))[rooms+1]+" per month");
                        System.out.print("\nAnother? (y/n): ");
                        another = in.readLine();         
            catch(Exception e){
                System.out.println("error - program terminated");
    public void readDataFromFile(String filename)throws Exception {
    BufferedReader br = new BufferedReader(new FileReader(filename));
    String line = "";
    while((line = br.readLine()) != null)
    floors.add(line.split(" "));
    br.close();
    public static void main(String args[])throws IOException{
    new FlatCost(args[0]);
    }any help is appreciated
    thanks
    Sarah x

    I barely know where to begin.
    Start by printing out the stack trace when you catch an exception. That'll give you more information than the message you're printing out. You know the program is terminating - you need to know why.
    You're writing in a VERY procedural style. There's little or nothing object-oriented about what you're doing.
    You've got a bunch of stuff in that constructor that really doesn't belong there. You shouldn't have code to continuously ask a client for a floor and room number in a constructor. That really belongs in an application that drives the object, like the main method that you wrote.
    Your FlatCost can read in a file that contains floor/room/price information, but if I were writing the application I'd read it in and store it in the ArrayList as you've done. Then I'd have a getCost() method that would take floor and room count as parameters and return the total cost.
    Learning how to program is learning how to debug. I'd rewrite things a little bit and put System.out.println() statements into the code to narrow down exactly where the error was occurring and why. It won't take you long to figure it out. You don't even need a fancy debugger or IDE.

Maybe you are looking for

  • User exit or Badi for ME21N transaction

    Hi Gurus, In ME21N tranasaction i need to make the field 'Free Item' ( checkbox ) as a mandatory field at item over view level for specific document types. so that user can't  save the PO order with out checking the checkbox. So is there any exit or

  • IMessage not functioning correctly

    since the last software update imessage works but if I turn iMessage off on another phone it will not send it as a text message automatically like it used to, i have made sure the send as SMS when iMessage is unavailable is on i have tried this on se

  • Setting Up Paypal Website Payments Pro Payment Gateway

    Hello, My customer is using Paypal Standard and the setup was straightforward and easy. Now we are looking at using Paypal Website Payments Pro Payment Gateway because we want to accept paid Events Bookings. My two questions: The instructions to set

  • Netware 5.1, mod_edir, Apache 2.0

    I've been fighting with this for over a week now. Here's my setup Novell 5.1 server SP7 eDirectory 8.7.3.9 Apache 2.0.59 Netware mod_edir 1.0.13 The configuration MUST use LDAPS Whenever I try to login when the "require edir-user" parameter is specif

  • Filling Data in Dynamic internal table

    Hello, I have 2 internal tables TAB1 and TAB2. I have Created Dynamic internal table From TAB1 rows. Now I want to fill that Dynm. internal table from TAB2. But TAB2  have more Rows with diffarant  names.  I want to move particular field of TAB2 to p