How to localize test cases?
To identify components, jemmy and jelly use mainly window’s titles, button’s label and other strings bound with searched component. It is good practice to collect such strings in Bundle.properties files to enable their later localization. We can benefit from such approach and use strings directly from bundles. If there are not hard coded strings in our test cases, they will work on every locale to which tested product is translated. For example to get localized string for menu item “Copy” under Edit menu in NetBeans IDE, we need to call Bundle.getStringTrimmed(“org.openide.actions.Bundle”, “Copy”). We have to know location of Bundle.properties file in java hierarchy and key of searched string. NetBeans IDE contains support for easier investigation of string source. If you run IDE with parameters -nosplash -J-Dorg.openide.util.NbBundle.DEBUG=true, every string in IDE is followed by ordinal number of bundle file and line number of the key within that file. By the ordinal number you can s