Wednesday 17 July 2013

website load or performance testing analysis or check points


http://lmohan.blogspot.co.uk/2010/01/checklist-for-performance-testing.html
http://loadtracer.com/performance%20testing%20approach.pdf
http://www.softwaretestinghelp.com/sample-test-cases-testing-web-desktop-applications/
http://www.guru99.com/complete-web-application-testing-checklist.html
http://www.neotys.com/product/neoload-cloud-testing.html

Performance Testing Test Scenarios

1. Check if page load time is within acceptable range
2. Check page load on slow connections
3. Check response time for any action under light, normal, moderate and heavy load conditions
4. Check performance of database stored procedures and triggers
5. Check database query execution time
6. Check for load testing of application
7. Check for stress testing of application
8. Check CPU and memory usage under peak load condition

Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.3.2:compile

 For this error you have to change JDK in your project..
Solution:
Step 1 : Right Click on  your project in Eclipse project Properties
Step 2 : Java Build Path >Libraries
Step 3 : Click on JRE > Edit > Installed JRE


Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.3.2:compile (default-compile) on project FundTransfer: Compilation failure
[ERROR] Unable to locate the Javac Compiler in:
[ERROR] C:\Program Files\Java\jre7\..\lib\tools.jar
[ERROR] Please ensure you are using JDK 1.4 or above and
[ERROR] not a JRE (the com.sun.tools.javac.Main class is required).
[ERROR] In most cases you can change the location of your Java
[ERROR] installation by setting the JAVA_HOME environment variable.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.

Solution by images step by step

Step 1 : Right Click on  your project in Eclipse project Properties

 Step 2 : Java Build Path >Libraries
 And after that click on JRE library so that Edit button will be enabled.
 Now click on Installed JRE button.

 Click on this line
Now change your JDK path
C:\ProgramFiles\Java .. under this path you will get JDK folder. give that folder and click on finish.





Tuesday 16 July 2013

How to import project from SVN to eclipse

Click on File-> import

Select SVN
after this you will get popup window as shown below.


Now select create a new repository
Here give SVN url

At Authentication

If your SVN has User and Password  fill those and click on Finish.

what is comment format in SVN

JIRAID-89 - your name comes here #comment Here you can give comments selenium automation framework grid checking in all folders.

Monday 15 July 2013

how to install or Integrate SVN or subversion into Eclipse


http://www.mkyong.com/eclipse/how-to-enable-subversion-svn-in-eclipse-ide/


http://www.ibm.com/developerworks/library/os-ecl-subversion/

Some people use Subversion it helps to integrate directly to the eclipse

If you want to use with out eclipse you can use tortoise software.
http://tortoisesvn.net/

how to install Testng on eclipse

http://selftechy.com/2012/01/09/setting-up-testng-with-eclipse

Unable to locate the Javac Compiler in

Step 1 : Right Click on Eclipse project Properties
Step 2 : Java Build Path >Libraries
Step 3 : Click on JRE > Edit > Installed JRE


[ERROR] Unable to locate the Javac Compiler in:
  C:\Program Files\Java\jre7\..\lib\tools.jar
Please ensure you are using JDK 1.4 or above and
not a JRE (the com.sun.tools.javac.Main class is required).
In most cases you can change the location of your Java
installation by setting the JAVA_HOME environment variable.
[INFO] 1 error
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1.075s
[INFO] Finished at: Mon Jul 15 14:58:07 BST 2013
[INFO] Final Memory: 9M/484M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.3.2:compile (default-compile) on project MySelProj: Compilation failure
[ERROR] Unable to locate the Javac Compiler in:
[ERROR] C:\Program Files\Java\jre7\..\lib\tools.jar
[ERROR] Please ensure you are using JDK 1.4 or above and
[ERROR] not a JRE (the com.sun.tools.javac.Main class is required).
[ERROR] In most cases you can change the location of your Java
[ERROR] installation by setting the JAVA_HOME environment variable.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException

Could not start a new session. Possible causes are invalid address of the remote server or browser start-up failure.

For this we have update IE Driver with latest.
And check what is your operating system whether 32 bit or 64 bit.

The below one is 64 bit one..

https://code.google.com/p/selenium/downloads/detail?name=IEDriverServer_x64_2.33.0.zip&can=2&q=

Could not start a new session. Possible causes are invalid address of the remote server or browser start-up failure. Build info: version: '2.32.0', revision: '6c40c187d01409a5dc3b7f8251859150c8af0bcb', time: '2013-04-09 10:39:28' System info: os.name: 'Windows 7', os.arch: 'amd64', os.version: '6.1', java.version: '1.7.0_21' Driver info: driver.version: RemoteWebDriver
org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:548)
at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:216)
at org.openqa.selenium.remote.RemoteWebDriver.<init>(RemoteWebDriver.java:111)
at org.openqa.selenium.remote.RemoteWebDriver.<init>(RemoteWebDriver.java:129)
at com.selenium.test.Utils.init(Utils.java:169)
at com.selenium.test.DriverScript.setUp(DriverScript.java:43)
20 lines not shownCaused by Connection reset
java.net.SocketInputStream.read(SocketInputStream.java:189)
at java.net.SocketInputStream.read(SocketInputStream.java:121)
at org.apache.http.impl.io.AbstractSessionInputBuffer.fillBuffer(AbstractSessionInputBuffer.java:166)
at org.apache.http.impl.io.SocketInputBuffer.fillBuffer(SocketInputBuffer.java:90)
at org.apache.http.impl.io.AbstractSessionInputBuffer.readLine(AbstractSessionInputBuffer.java:281)
at org.apache.http.impl.conn.DefaultHttpResponseParser.parseHead(DefaultHttpResponseParser.java:92)
at org.apache.http.impl.conn.DefaultHttpResponseParser.parseHead(DefaultHttpResponseParser.java:62)
at org.apache.http.impl.io.AbstractMessageParser.parse(AbstractMessageParser.java:254)
at org.apache.http.impl.AbstractHttpClientConnection.receiveResponseHeader(AbstractHttpClientConnection.java:289)
at org.apache.http.impl.conn.DefaultClientConnection.receiveResponseHeader(DefaultClientConnection.java:252)
at org.apache.http.impl.conn.AbstractClientConnAdapter.receiveResponseHeader(AbstractClientConnAdapter.java:219)
at org.apache.http.protocol.HttpRequestExecutor.doReceiveResponse(HttpRequestExecutor.java:300)
at org.apache.http.protocol.HttpRequestExecutor.execute(HttpRequestExecutor.java:127)
at org.apache.http.impl.client.DefaultRequestDirector.tryExecute(DefaultRequestDirector.java:712)
at org.apache.http.impl.client.DefaultRequestDirector.execute(DefaultRequestDirector.java:517)
at org.apache.http.impl.client.AbstractHttpClient.execute(AbstractHttpClient.java:906)
at org.openqa.selenium.remote.HttpCommandExecutor.fallBackExecute(HttpCommandExecutor.java:316)
at org.openqa.selenium.remote.HttpCommandExecutor.execute(HttpCommandExecutor.java:295)
at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:527)
at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:216)
at org.openqa.selenium.remote.RemoteWebDriver.<init>(RemoteWebDriver.java:111)
at org.openqa.selenium.remote.RemoteWebDriver.<init>(RemoteWebDriver.java:129)
at com.selenium.test.Utils.init(Utils.java:169)
at com.selenium.test.DriverScript.setUp(DriverScript.java:43)
20 lines not shown

Thursday 11 July 2013

What is Log4j and what is the use of log4j in java

With log4j it is possible to enable logging at runtime without modifying the application binary. The log4j package is designed so that these statements can remain in shipped code without incurring a heavy performance cost. Logging behavior can be controlled by editing a configuration file, without touching the application binary.

Logging equips the developer with detailed context for application failures. On the other hand, testing provides quality assurance and confidence in the application. Logging and testing should not be confused. They are complementary. When logging is wisely used, it can prove to be an essential tool.

To add to this, with Log4J you can dynamically switch logging on/off. You can change the format dynamically (do you want timestamps ? datestamps ?) and you can change where the logging goes (to the console ? to a file ? to a database ?), all without changing your code.

You can also log to multiple sources at once. In an application I'm working on now, when I'm testing the application, I log to both the console (so I can see debug information as well as any errors that pop up) along with the standard log file that's always logged to. Quite handy

The beauty of log4j is in its architecture of appenders and layouts. As mentioned by previous poster, you change the aspect of logging of your application without much hassle, most of the time it's just a matter of simple configuration. One of the usages I would add on my part is centralized logging which can be added to your application without touching its code base

Wednesday 10 July 2013

what is maxSession maxInstances in selenium grid and differences

MaxInstances This says....how many instances of same version of browser can run over the Remote System.

For example, I have a FireFox12,IE and I declared the command as follows
-browser browserName=firefox,version=12,maxInstances=5,platform=LINUX
-browser browserName=InternetExplorer,version=9.0,maxInstances=5,platform=LINUX
So I can run 5 instances of Firefox 12 and as well as 5 instances of IE9 at the same time in remote machine. So total user can run 10 instances of different browsers (FF12 & IE9) in parallel.

MaxSession This says....how many browsers (Any Browser and any version) can run in parallel at a time in the remote system. So this overrides the Max Instances settings and can restrict the number of browser instances that can run in parallel.

For above example, when maxSession=1 forces that you never have more than 1 browser running.

With maxSession=2 you can have 2 Firefox tests at the same time, or 1 Internet Explorer and 1 Firefox test).
Irrespective of what MaxInstances you have defined.

How to create table of content on excel sheet

Thursday 4 July 2013

How to give comment on Json file

 "_comment" : "comment text goes here...",
The JSON should all be data, and if you include a comment, then it will be data too.

You could have a designated data element called "_comment" (or something) that would be ignored by apps that use the json data.

You would probably be better having the comment in the processes that generate/receive the json, as they are supposed to know what the json data will be in advance, or at least the structure of it.

But if you decided to...

Monday 1 July 2013

Firefox can't find the server at services.addons.mozilla.org

Firefox can't find the server at services.addons.mozilla.org

whenever you try to add some addons on your firefox browser ... then this type of error will come.

So if you want to install example firebug , firepath addons...
download those addons to here
C:\Windows\temp

And then Tools->addons

under Get addons select add ons manually from temp folder and install.