Welcome To User Friendly Software Technical concepts

This Blog contains information of various technical concepts,The concepts are precise,informative with examples.visitors can easily understand the concepts of different technical related subjects like software Testing concepts , practice questions on sql And JMeter(Open source automation tool ) for Performance testing of an web application and about selenium tool used for functional testing of an web application

Tuesday, August 31, 2010

Detailed about What is Test Case

Test case
  • Test case can be defined as written down document by referring to which we validate applications.
  • A test cases help us exactly how to test should be carried out.
  • The systems test case help us verify an validate the system
  • Test cases are written by referring to requirements(document)
  • A test case in software engineering is set of conditions and variables under
    which a tester will determine whether an application or system is working correctly or not.
  • Test cases are often referred to as test scripts
  • Test case contains the data against which we test the application.
  • The test cases are written such that they cover all the scenerios
  • The test case verify validate the technical requirements and specifications
  • The test case verify if the application or system meet the business and functional requirements specified
  • The test case may also verify if the system meets the performance standards

Monday, August 30, 2010

Compatibility Testing

Compatibility Testing
It is a type of Non functional testing
Testing the behaviours of the application on different hardware and software configurations.
Testing conducted on the application to evaluate the application compatability with the computing environment.

computing environment may contain below mention element
1)computing capacity of hardware platform (IBM 360)
2)Bandwidth handling capacity of networking hardware
3)compatability of pheripherals
4)Operating systems(printer.Dvd drive etc)
5)Data Base(oracle)
6)other system software(web server etc)
7)Browser compatability(Firefox,Netscape,safari etc)

Wednesday, August 25, 2010

Selenium xpath

Selenium xpath
Selenium xpath are orginally written for xml files.It is very similar to HTML.
When there no id or name in the html expression selenium uses xpath to identify the elements.
For Example: 


< input type="submit" 
value="login now" valign="absmiddle"/>



In above example there is no id or name so selenium uses xpath to identify the elements to perform the action.
For Example:


  
< input type="submit" 
value="login now" valign="absmiddle"/>

Saturday, August 21, 2010

Static and Dynamic testing

Static and Dynamic testing
Static Testing:
1)Analysis of program is carried out without executing program.
example:Reviewing,walk through

Review:An evaluation of a product or project status to ascertain
discrepancies from planned results and to recommend improvements.

Walk Through: A step by step presentation by the author
of a document in order to gather information and to establish
a common understanding of its content.


Friday, August 20, 2010

Prototype Testing

                                                                             Testing

Prototype Testing
It  involves the testing of prototype developed

It includes testing color,word,spelling,label,size,length etc..
of the dummy screen.


Advantages
1)The changes in prototype can made with least efforts ,compared
to change made on real applications,

2)No confusions between company and customer.

3)The software designer and implementation  can obtain feedback
from users early in the project that if there are any changes it
can be done before the actual design.

4)Quality of the application will be good.

5)prototype can also used by end users to describe and prove
requirements that developers have not considered.

Disadvantages
1)Resource,time,cost used is more

2)prototypes(dummy screens) might be wasted.

Thursday, August 19, 2010

Mutation Testing

Mutation Testing
Mutation Testing is a method of software testing which involves
modifying programs source code in small ways.

Mutation testing is forcibly injecting bugs and testing the
application.

It means making changes in code and testing how application
works.

Mute means Bug ,In this testing programmer intentionally
introduce the  bug and validates completeness and correctness
of the program.

Comparison Testing

Comparison Testing
In comparison testing , testers compare the old application
with new application and see whether the new application is
working better than the old application.

Testers will compare the strengths and weakness of new product  with the
existing product which is already in use.

Comparison Testing is needed to improve the quality of the product by
removing weakness of the new product.

Tuesday, August 17, 2010

JMeter Samplers and Assertions

Samplers and Assertions :

1) SAMPLERS:Samplers tell JMeter to send requests to a server and wait
for a response.


JMeter samplers include: 
FTP Request 
HTTP Request
Java object request 
LDAP Request 
SOAP/XML-RPC Request 
WebService (SOAP) Request

Sunday, August 15, 2010

Security Testing

Security Testing




Testing the security of application that how well it protects
the data from unauthorized entry.


The process to determine that an information system
protects how well it protects data and maintain
functionality as intended.


The six basic security concepts that needed to be covered
in security testing are:
confidentiality
Integrity
authentication
authorization
availability
non-repudiation



Confidentiality:
A  security measure which protects against the disclosure of
information against disclosure of information to parties
other than intended persons by no means ,the only
way of ensuring the security.


Integrity:
A measure intended to allow the receiver to determine the
information which it is providing is correct.

Authentication:
Allows a receiver to have confidence that information it receives
is origination from specific known resource.

Authorization:Access control
The process of determining that a request is allowed to receive
a service or perform an operation.

Availability:Assuring information and communication services
is ready for use when expected only bt the authorized users.

Non-Repudiation: A measure intended to prevent the later denial
that an action happened ,or a communication took place.

Some examples of security Testing are:
    Examples1:
  • When user Login to new session there will be one session pool
    and one number is generated and this is dropped in to local
    machine
    c:\prog files\window\temp
    session id=cookie
  • When you logotype the cookie gets deleted that is cookies
    get back into browser.
  • Login to web application
  • Go to c:\prog files into notepad 
  • logout
  • once again paste into path then try to open it without
      user name and password,It should not login because each time
    different random numbers are generated.
  • session id should get expired as soon as user logout.
    This is security testing

    Example2
    :
    1)Take notepad ,write user name and password
  • copied user name and password is then copied into
      user name and password fields of the application.
  • once again copy and paste it in notepad,it should
    not be decoded.

    Example3:
  • Logout  and click on the back arrow,it should not once again
    go back to application









Reliability Testing



Reliability Testing
In case of electronic voting machine due to more use or continuous
clicking of Buttons the machine may not work.

Testing the precession(accuracy) of the fuctionality of the
application over a period of Time.

The ability of a system or component to perform its required
fuctions under stated conditions for a specified period of Time.

Done for standard application.

Example1)Load Runner : Run the application for many hours
        set time 70hrs,92hrs,120hrs
2)There should be no change in functionalities even after many hours
   example:Gaming applications.

Friday, August 13, 2010

Basics of Jmeter

1) To work with Jmeter

Install JDK software which is used for java application.
Then install Jmeter
After installation,go to “bin” directory.
Double click on “Jmeter.bat”


JMeter proxy Step-by-step

To record the requests sent to the server follow the below mentioned steps

2) The main screen loads two elements in the left pane
Test Plan

The Test Plan is a container for running tests

Workbench.
The Workbench is a sandbox for any test or portion of a test that you
are working on. When you are ready to test what you have designed in
the Workbench, you can copy or move the elements into the Test Plan.



3) Right click on workbench and add the HTTP proxy: add
   -> non-test elements -> HTTP Proxy Server.

  Click on start button at the bottom of the  window.

4)


5) Start Internet Explorer, but do not close Jmeter.
6) From the tool bar, click “tools -> internet options”. This should bring up the     options.

7) Select the “connection” tab

8) Click “LAN settings”  button near the bottom.

9) On the connections tab, check “Use a proxy server for your LAN”. The address and port  fields should be enabled now.

10) Address – enter “Local host” or the IP address of your system

11) Port – enter “8080”.

12) Click “OK” button

13) Click “OK” button again. This should return you to the browser

14) In the “Address” bar at the top, enter   WWW.gmail.com           
and  hit the “enter” key.

15) Click on a few links on “Gmail page”  page.

16) Close internet explorer and bring up the Jmeter window.

17) Right click on the testplan and click add>thread group



18) Select “Thread group” and enter Number of threads 
  ,Ramp up Period, Loop   count .

19) Copy the paths from “Work bench” into “Thread group”.

20) Right on the Thread group ->add - > listener -> summary report .

21) 21) Save the test plan.
22) When you're ready to run the test, there's two ways:

                 1. Run -> Start
                 2. CRTL – R
 
23) While the test is running, in the upper right-hand corner, there should be a green square.
When the test is done, the box should be Grey.

Glossary

Thread Groups
A thread group allows you to define the behavior of a group of threads that will interact with your application. Think of each thread as a person sitting at their computer, trying to access a given Web page. You will use thread groups to define the number of threads that a test will launch.



Number of Threads -- You can enter as many threads to stimulate a load test. A single user is represented by each Thread so if you wish to simulate a load test with 5 concurrent users then you need to enter 5 as the value for this property.    

         
Ramp-Up Period -- It indicates the time taken by Jmeter to create all of the threads needed. If you set 10 seconds as the ramp-up period for 5 threads then the JMeter will take 10 seconds to create those 5 threads. Also by setting its value to 0 all the threads can be created at once.  

                                                
Forever -- If you choose this option then the Jmeter will keep sending the unspecific requests to the tested application. And if disabled then the test will be repeated the number of times entered in the Loop Count box.        

                                                                                    
Loop Count -- By specifying its value Jmeter gets to know that how many times a test is to be repeated provided that the Forever check box should be unchecked.      

Listeners :
Listeners gather data as your tests run, and allow you to report on that data. You can use listeners to create graphs or export data to files.
      

Wednesday, August 11, 2010

Performance Testing(Load,stress,volume ,soak, spike,scalability)


Performance testing:

Performance testing of an application / system is basically the process of
understanding how the application and its operating environment behave at
various user loads.
In general, it is performed by simulating virtual users to determine / validate the
scalability, availability, robustness, hardware & software resource utilization of the
application thus ideally paving the way for effective capacity planning of the system for
future usage. One of the main objectives of performance testing is to help maintain the
system with low latency, high throughput, and low utilization.

Testing the stability and the response time of an application by
applying  different loads is called performance Testing

Stability:Ability to withstand a designed numbers of users.
Response Time:Time taken to run the program,send the request
                and receive the response.This should be
                minimum when any application runs.

If 1500 users access at a time and due to load the system
may getcrashed then it has poor stability. If it is not gets
crashed thencheck the response time.Response Time should
be low.



Need for Performance Testing
Performance Testing sets the ‘best possible’ performance expectation under
a given configuration of infrastructure.
It also highlights early in the testing process if changes need to be made before a
pplication goes into production.

Types  of Performance Testing:
Load Testing:A Load test is usually conducted to understand the
                Behavior of an application under a specific
expected Load.

"Testing the stability and response time of an application by
applying loadin which it is equal to or less than designed numbers 
of usersperforming a specific operation no of transactions within the
set duration".

Stress Testing:







Stress Testing:
This testing is normally used to break the application.Double the
no of usersadded to the application and test is run again until
the application break down.
This is done to determine the application robustness in the times of
extreme loads and helps application administrator to determine if the
application willperform sufficiently if the current load goes above the
expected load.

Example:If it is designed for 100 users and configuration 1ghz
processor with speed 1ghz Rom,Reduce the network the configuration
               and keep the numbers of users constant.


Volume Testing:Testing the stability and response time of an application
                            by transferring or processing huge volume
of data.

Soak Testing:Test the stability and response time of an application
              of an application by applying Load continuouslyfor particular
period of time.
It is also  known as  endurance Testing

For Example : Test the application for 72hrs(3days),96hrs(4 days)
and 120hrs(5days).If it works well for 3 days thenwe can  ensure for
1 year it will work fine.

spike testing:It is done by spiking the number of users
 (Increasing or changing the load) and understanding the behavior
of the application whether  it will go down or will it be able to
handle dramatics(sudden) changes in load.

Scalability Testing: It is Testing of software application for
measuringits capability to scale out(There will besome standards
if measures beyond that its scale out)in terms of any of its non
functional capabilitieslike user load supported the number of
transactions,and the data volume.

Functional and Funtionality Testing

Functional  and Functionality Testing

Functional Testing:
After completing the user interface testing test engineers
concentrateon Functional testing  to validate the customer 
requirements.

 Note : User interface testing:Testing three factors on every screen
of the build.
                           1) Ease to use 
                            2)Look and feel(GUI)
                            3)Speed in interface

 Functional testing involves  testing each component is working
fine or not.
For example:1) For Email field if testers enter invalid data whether
it showing warning or not.(Validation)
              2)For Fax field testers enter  invalid data like alphabets
showing warning or not..

A procedure to drive and /or select test cases based on analysis
of the specification of the functionality of a component or system
without reference to its internal structure or internal logic.

  • Testing the product features at early phase of  the Life cycle

Functionality Testing
  Functionality testing is nothing but to test whether product or application
 is build as per customer requirement specified in system requirement
specification.

For Example:
1) SRS  specifies application should work in multiple
  Browser. 
2)customer specifies in a email, user should have
  privilege to  specify the number of mails at once.

3)In Gmail application by clicking logout button it should
return back to home page.

In above examples there is certain logic that  customer specified
in srs.Testing this kind of scenarios is called Functionality Testing .

Functionality testing is nothing but to test whether product or
applicationis build as per customer requirement specified in system
requirement specification.

Testing the product features at every phase of the life cycle that is
Adhoc Testing,Integration Testing and System Testing.

Tuesday, August 10, 2010

System Testing

         
         
         
        
         
          System Testing:
  • It is end-to-end testing ,testing where in testing
    environment is just like in production environment .
  • Navigate through all features and check whether
    end features are working or not.
  • Testing the overall behavior of an application by
    simulating an environment which is just by simulating
    an environment which is just like the production
    environment.
  • To do system testing we have to identify end-to-end
    scenario.
  • It is the test conducted by navigating through modules.
  • system testing is performed on the entire system in the
    context of a Functional requirement specification
    or system requirement specification.
  • It is also intended to test beyond the bounds defined in
    system requirement specification.

      Example:In a Bank
      Fist time :
      Loan amount :20000
      Rate of interest =2%=400
      processing  fee:250

    while repaying the loan he has to pay 20650

      second time :

      Loan amount :20000
      Rate of interest :400
      No processing fee
      Repayable:20400

       steps:-
  •    Login as x and apply for 20000
  •    After applying ,Logout
  •    login as manager then approve the loan for x
  •    logout as a manager
  •    login as x and check the balance and it should be
       20000
  •    come back to amount balance ,20000 is there.
  •    logout as x
  •    login as database access and change the server time to
       next month
  •    logout as data base access 
  •    login as x and check the loan amount to be repaid as
       20650
  •    login as y and transfer 650 rs to x
  •    logout as y
  •    login as x and check the balance 20650, repay loan


  •   Here all modules like manager module ,
     savings,amount transfer,Data base access,loan
      module are working properly.
  •   It is like master checkup.
  •   For example :when many users use the same
      application system become slow or clash due
      to load.
      If the load on the system is resistible then
      we can say whole system is working properly.
  •   what ever test is done on the overall
      system it is called system testing or
      end -to-end testing.

Monday, August 9, 2010

Accessibility Testing


 Accessibility Testing:
Testing the application from the physically challenged persons point of view.
It is also called American disability Act or 508 testing.

American disability testing

1)No objects/Results should referred by any colors.
   Example: Instead of green and red, Fail and pass should be there.
2)proper visual and audio effect.
3)All the images should have Tool tip which reduces the pain
of physically clicking mouse by person.


Tool:-A-Prompt
This tool does the  accessibility by navigating all pages of applications.


Testing to determine the ease by which users with disabilities
can use a component or system.

Testing the application with respect to physically challenged
persons point of view is called  Accessibility Testing:

Gui Testing

Gui Testing
Gui testing is also  a part of functional testing


Examples

1)Tab key:-The cursor should move to next edit field
upon pressing the tab key.
  Shift+Tab should work in reverse order.

2)Spellings:Testers should check for spellings.

3)Position of objects:Testers should check for position of
objects.


4)Default cursor focus:By defaults the cursor should be in
the usernamein login screen and from account no in the amount
transfer screen.

5)Enter key:After entering data if we press enter key it should login.

6)same height and width:same height and width of the
objects belonging to same class.


7)Enabling and Disabling of objects:For eg sign in
button should bedisabled to the username and password is
entered..

8)key board Functionality:shortcut  keys should also work
properly

9)confirmation and invalid message must be displayed at appropriate time.

Structured query Language Questions


TABLE : DEPT

   DEPT NO
DAME
      LOC
  10
ACCOUNTING    
NEW YORK
  20
RESEARCH     
 DALLAS
  30
SALES         
CHICAGO
  40
OPERATIONS   
 BOSTON


TABLE : EMP

EMPNO
ENAME
JOB
MGR
HIREDATE
SAL
COMM
DEPT NO
7369
SMITH
CLERK
7902
17-Dec-80
800

20
7499
ALLEN
SALESMAN
7698
20-Feb-81
1600
300
30
7521
WARD
SALESMAN
7698
22-Feb-81
1250
500
30
7566
JONES
MANAGER
7839
2-Apr-81
2975

20
7654
MARTIN
SALESMAN
7698
28-Sep-81
1250
1400
30
7698
BLAKE
MANAGER
7839
1-May-81
2850

30
7782
CLARK
MANAGER
7839
9-Jun-81
2450

10
7788
SCOTT
ANALYST
7566
9-Dec-82
3000

20
7839
KING
PRESIDENT

17-Nov-81
5000

10
7844
TURNER
SALESMAN
7698
8-Sep-81
1500
0
30
7876
ADAMS
CLERK
7788
12-Jan-83
1100

20
7900
JAMES
CLERK
7698
3-Dec-81
950

30
7902
FORD
ANALYST
7566
3-Dec-81
3000

20
7934
MILLER
CLERK
7782
23-Jan-82
1300

10




                                                  Questions ON OPERATORS


   1)    Display all the employees who are getting 2500 and excess salaries in department 20.

2)    Display all the managers working in 20 & 30 department.

3)    Display all the managers who don’t have a manager

4)    Display all the employees who are getting some commission with their designation is neither MANAGER nor ANALYST

5)    Display all the Analysts whose name doesn’t ends with ‘S’

6)    Display all the employees whose naming is having letter ‘E’ as the last but one character

7)    Display all the employees who total salary is more than 2000.
(Total Salary = Sal + Comm)
         
8)    Display all the employees who are getting some commission in department 20 & 30.

9)    Display all the managers whose name doesn't start with A & S

10)  Display all the employees who earning salary not in the range of 2500 and 5000 in department 10 & 20.


QUESTIONS ON GROUPING


11)   Display job-wise maximum salary.

12)   Display the departments that are having more than 3 employees under it.

13)   Display job-wise average salaries for the employees whose employee number is not from 7788 to 7790.

14)   Display department-wise total salaries for all the Managers and Analysts, only if the average salaries for the same is greater than or equal to 3000.

Consider the following table: -

     Questions 5,6,7 & 8 are based on the following table



Table Name : SKILLS


ID
Name
101
Oracle
102
Oracle
103
Oracle
101
Oracle
102
Java
103
Java
101
Java
102
Java
103
Java
101
Java
101
Java
101
Oracle
101
VB
102
ASP

15)   Select only the duplicate records along-with their count.
16)   Select only the non-duplicate records.

17)   Select only the duplicate records that are duplicated only once.

18)   Select only the duplicate records that are not having the id=101.

Questions ON SUB QUERIES


19)    Display all the employees who are earning more than all the managers.

20) Display all the employees who are earning more than any of the managers.

21) Select employee number, job & salaries of all the Analysts who are earning more than any of the managers.

22) Select all the employees who work in DALLAS.

23) Select department name & location of all the employees working for CLARK.

24) Select all the departmental information for all the managers

25) Display the first maximum salary.

26) Display the second maximum salary.

27) Display the third maximum salary.

28) Display all the managers & clerks who work in Accounts and Marketing departments.

29) Display all the salesmen who are not located at DALLAS.

30)               Get all the employees who work in the same departments as of SCOTT.

31)               Select all the employees who are earning same as SMITH.

32)               Display all the employees who are getting some commission in marketing department where the employees have joined only on weekdays.

33)               Display all the employees who are getting more than the average salaries of all the employees.



Questions ON JOINS

Questions ON EQUI-JOINS

34) Display all the managers & clerks who work in Accounts and Marketing departments.

35) Display all the salesmen who are not located at DALLAS.

36) Select department name & amp; location of all the employees working for CLARK.

37) Select all the departmental information for all the managers

38) Select all the employees who work in DALLAS.

39)               Delete the records from the DEPT table that don’t have matching records in EMP


Questions ON OUTER-JOINS

40)  Display all the departmental information for all the existing employees and if a department has no employees display it as “No employees”.


41) Get all the matching & non-matching records from both the tables.


42) Get only the non-matching records from DEPT table (matching records shouldn’t be selected).


43) Select all the employees name along with their manager names, and if an employee does not have a manager, display him as “CEO”.


Questions ON SELF-JOINS

44) Get all the employees who work in the same departments as of SCOTT


45) Display all the employees who have joined before their managers.




46) List all the employees who are earning more than their managers.


47) Fetch all the employees who are earning same salaries.


48) Select all the employees who are earning same as SMITH.
49)               Display employee name , his date of joining, his manager name & his manager's date of joining.