Some Rules in Java:

  • A source code file can have only one public class and may have multiple non-public class
  • A public class  file name must match the public class name.
  • A file can have only one package statement and it must be the first line in the source code.
  • A file can have multiple imports.
  • Import statement is applicable to all classes in the source code file
  • If a class cannot be accessed, its members (methods and instance variables) cannot be accessed either.
  • A subclass can inherit a member of its super-class.A subclass can only extend one parent.
  • A class access determines its members' access. If a  class cannot be access, its member's cannot be accessed either.
  • 'this.' means currently executing object.
  • Private members cannot be inherited.

Java - Package

What is a package?
A package is a kind of directory that contains a group of related classes and interfaces. Packages hides its class and interfaces in a separate directory. Java has many such packages it its library. If you want to use a classes, you  have to import it into your program. If you want to use a method, then you have to import the corresponding class or interface.
A group of package is called library. Any class and interface inside a package is reusable.When a package is imported, its sub-packages are not automatically imported into a program. A separate import statement should be written to for every package or sub-package.

Java library
      |
Packages
      |
Classless and interfaces
      |
methods

There are two different types of packages.
1. build-in
2. User defined 
Build -in Packages
Build -in packages are already available in Java. These packages provide all necessary classes, interfaces and methods to perform tasks. Some important packages are:
java.lang:   This package has primary classes and interfaces for developing a basic Java program.
java.util: It has many useful collections. Date, time operations, victors... 
java.awt: awt stands for Abstract Window Toolkit.This package is useful for developing GUI-color, paintings, images etc. It consists one important sub-package java.awt.event. It provides actions like select radio button, menu etc.
javax.swing: Helpful for GUI. It is an extended package of java,awt(package developed from another package by adding new features). 'x' represents it as an extended package.
java.net: Useful for authentication for network, creating sockets, to establish communication between client-server.
java.applet: Related to Java applets.
java.text: It contains two important classes. 'DateFormat' is to format date and time. 'NumberFormat' is to format numeric values.
java.sql: Helps to connects to the database like oracle, retrieve and use data in Java program.

User-Defined Package: 
Package created by user. User defined package can be used exactly same way as the build-in package. 
The keyword to create a package is package.

Features related to the Object Oriented Programming Systems(OOPS)

The root  concept of the object oriented programming(OOP) is 'Object' and developing programs using class and object. OOP languages allow programmers to use and reuse the same modules multiple times.You yourself are an 'object'. Tell me about yourself,(properties) - name - yoyo, age- 28.What can you do(methods) eating-eat(), running - run()
In JAVA  there is a main task to perform(Main method). That one task is divided into many modules(classes). Each class can perform certain task. Many methods are written inside a class to perform actions with data(variable). So variables and methods are also called 'members' of the class.

Some features of OOP are
Class/object:
Access Specifiers:
An access specifier is a key word that specifies how to access the member of classes or a class itself. There are four access specifiers in Java:
Private:  'Private' members of a class are not accessible anywhere outside the class. They are accessible only within the class by the methods of that class.
Public: Public member of a class are accessible from everywhere.
Protected: Accessible outside the class but only within the same directory.
Default: If not specified by a programmer, it is 'default' . Default members are accessible outside the class, bur within the same directory.Private for instance variable. Public for  methods, class.
Constructors: 
Encapsulations:
Abstractions
Inheritances
Polymorphism

Selenium IDE and its useful features

Selenium IDE, a Firefox extension is the easiest way to record, edit, debug and run web test. Selenium is a web application testing system and selenium IDE (sometime refereed as SIDE) is a part of it. Once download, it appears as a Firefox plug-in under 'tools'. Selenium IDE works only with Firefox browser. A Selenium test recorded in Selenium IDE can be run in other browsers with the Selenium Server.
Installation:
You can download Selenium IDE from:
If you want to open it, lunch the Firefox browser then go to, Tool > Selenium IDE. You will see the following window.


Selenium IDE is a lightweight tool and it doesn't have a lot of features as well. Some of the important features are:
Base URL: Base URL of the application. Selenium IDE automatically captures it.
User Extensions: You can add new actions and assertions in selenium IDE with JavaScript. Create your own user-extension and save it as .js file. Go to Tools > Options and browse your js file here. Next time when you open lunch your Selenium IDE, it will be available in command drop-down. To learn more about Selenium User Extension visit here.
Test Case and Test suite:
Under 'file' menu there are options to open, save, save as and export test case and test suite. Saving as a test suite help to create a test suite and add test cases inside it.
Help:
Help takes you to "Selenium UI-Element Reference". If you are a beginner, it is a place worth visiting.

Selenium HTML-Testrunner framework with 2.0rc2

There are so many languages and frameworks for selenium, such as JAVA- JUnit framework, and C#- .Net. These are excellent if you are comfortable with one of the languages and tools. It will help you to create dynamic, advanced test framework according to your test need. Moreover, it opens door to use powerful development language in your test. For example if and else logic.
However, this HTML based Test Runner framework is easy and requires low maintenance. It is powerful enough for most of the automation need and you can use javaScript to make your test more meaningful if necessary. You as an automation tester do not need development language either.
Please follow these steps if you want to adopt this for your test automation purpose. I have used website Facebook log-in page for this tutorial. I am assuming you know about selenium IDE and recording the recording. If answer is ‘no’ then going to this page and come back here.

Download Selenium Server
  • Go to http://seleniumhq.org/download/. It is also known as Selenium Server. 
  • If you cannot   find stable build find from this page: http://code.google.com/p/selenium/downloads/list.
  • It is a .ZIP file. Once download is completed unzip it in C:\selenium
  • Test it.  To test it runs properly follow the following step:
1.   Open command line.
2.   Go to the folder that contains the selenium server. (You can go using DOS cd command to navigate from one folder to another.). Type following commands: java -jar selenium-server-standalone-2.0rc2.jar. If it runs successfully, you will see the following screen:


If it doesn't run check the error message. Usually, problem is with the port. Selenium server’s default port is 4444. If it is taken already, problem occurs. Easy solution is to restart your machine.

About

 Hello! welcome to my blog.
This blog is about software quality assurance, web/test development technologies,health information technology and interview questions-answers. Answers I have posted in this blog are all my point of views. I posted them because-- these are the frequently asked questions in my opinion-- to help those who are new to quality assurance and testing world or IT world in general. Dear visitors, you can also share and discuss answers so that someone can benefit from your contributions. Please share your experience, questions or answers to help other candidates to succeed in interviews. 
Thank you!
I always believe in giving my 100% to any role. I  believe in cooperation, the power of positive attitude and eagerness to help other in need.  Be enthusiastic about new technology and tools if you wish to be a successful professional in IT environment. Here learning never stops!!! 
Also, being a good human being helps you to be a meaningful asset in every place including at workplace. Be positive, hard working and never stop learning new things.


Update...



Currently I am focusing on Health Information Technology, known as Health-IT. Recent progress in the healthcare system has impacted and is going to impact everyone in the near future. We are very close to the implementation of  Affordable Care Act, known as Obamacare. Lets hope it will be beneficial to all of us ans medical bill will not be a nightmare. Hopefully there will be plenty of job opening in this area in 2014 and 2015 as well. I will update information related to Health Information Technology under HEALTH IT tab as I will go through  this journey myself. 



Thank you all!!!

ISTQB Question set # 1

 Highlight the area next to the 'Answer:' for right answer.

1. Which one of the following are non-functional testing methods?
a.  System testing
b.  Usability testing
c.  Performance testing
d.  Both b & c

Answer: d

2. Pick the best definition of quality
a.  Quality is job one
b.  Zero defects
c.  Conformance to requirements
d.  Work as designed

Answer:C

3. Boundary value testing...
a.  Is the same as equivalence partitioning tests
b.  Test boundary conditions on, below and above the edges of input and output equivalence classes
c.  Tests combination of input circumstances
d.  Is used in white box testing strategy

Answer: b

5. White Box Techniques are also called as
a.  Structural Testing
b.  Design Based Testing
c.  Error Guessing Technique
d.  Experience Based Technique

Answer: a

6. Which of the following is a MAJOR task of test planning?
a  Scheduling test analysis and design tasks.
b Initiating corrective actions.
c Monitoring progress and test coverage.
d Measuring and analyzing results.

Answer: a

7. Where may functional testing be performed?
a.  At system and acceptance testing levels only.
b.  At all test levels.
c.  At all levels above integration testing.
d.  At the acceptance testing level only.

Answer:
a

8. Who would USUALLY perform debugging activities?
a. Developers
b. Analysts
c. Testers
d. Incident Managers

Answer:
a

9. As part of which test process do you determine the exit criteria?
a. Test planning.
b. Evaluating exit criteria and reporting.
c. Test closure.
d. Test control.

Answer:
a

10.What is beta testing?
a. Testing performed by potential customers at the developers location.
b. Testing performed by potential customers at their own locations.
c. Testing performed by product developers at the customer's location.
d. Testing performed by product developers at their own locations.
 

Answer: b

11. A thermometer measures temperature in whole degrees only. If the temperature falls below 18 degrees, the heating is switched off. It is switched on again when the temperature reaches 21 degrees. What are the best values in degrees to cover all equivalence partitions?
a. 15, 19 and 25.
b. 17, 18 and19.
c. 18, 20 and22.
d. 16, 26 and 32.

Answer: a

12. Which of the following is TRUE?
a. Confirmation testing is testing fixes to a set of defects and Regression testing is testing to establish whether any defects have been introduced as a result of changes.
b. Confirmation testing is testing to establish whether any defects have been introduced as a result of changes and Regression testing is testing fixes to a set of defects.
c. Confirmation testing and Regression testing are both testing to establish whether any defects have been introduced as a result of changes.
d. Confirmation testing and Regression testing are both testing fixes to a set of defects.


Answer: a  

13. Deliverables of the test design phase include all of there except:
a. Test Data 
b. Test Data Plan
c. Test Summary report
d. Test Summary Plan 


Answer: c

14. Which of the following is not decided in the test-planning phase?
a) Schedules and deliverables
b) Hardware and software
c) Entry and exit criteria
d) Types of test cases

Answer: d

15. Deciding how much testing is enough should take into account:
i. Level of Risk including Technical and Business product and project risk
ii. Project constraints such as time and budget
iii. Size of Testing Team
iv. Size of the Development Team

a) i, ii, iii are true and iv is false
b) i, iv are true and ii is false
c) i, ii are true and iii, iv are false
d) ii, iii, iv are true and i is false


Referring to ISTQB Syllabus:
1.1.5 How Much Testing is Enough? (K2)
Deciding how much testing is enough should take account of the level of risk, including technical, safety, and business risks, and project constraints such as time and budget.  Risk is discussed further in Chapter 5.
Testing should provide sufficient information to stakeholders to make informed decisions about the release of the software or system being tested, for the next development step or handover to customers

Answer: c

16. Which of the following is not phase of the Fundamental Test Process?
a) Test Planning and Control
b) Test implementation and Execution
c) Requirement Analysis
d) Evaluating Exit criteria and reporting


Referring to ISTQB Syllabus:
1.4 Fundamental Test Process (K1) 35 minutes
The fundamental test process consists of the following main activities:
  • Test planning and control
  • Test analysis and design
  • Test implementation and execution
  • Evaluating exit criteria and reporting
  • Test closure activities
Answer: c

17. COTS is:
A. Commercial off the shelf software
B. Compliance of the software
C. Change control of the software
D. Capable off the shelf software

Answer: a

18. The bug tracking system will need to capture these phases for each bug.
I. Phase injected
II. Phase detected
III. Phase fixed
IV. Phase removed

A. I, II and III
B. I, II and IV
C. II, III and IV
D. I, III and I

Answer: B

19. Correct bug life cycle
A. Open, Assigned, Fixed, Closed
B. Open, Fixed, Assigned, Closed
C. Assigned, Open, Closed, Fixed
D. Assigned, Open, Fixed, Closed

Answer: A




 

Functions in SQL

General Functions:
NVL, NVL2


Character Functions: 
Character functions accept character data as an input and can return both character and numeric values. Character functions can be divided into case-conversion and character manipulation types.
LOWER, UPPER, INITCAP are the three case conversion functions. 
Some Character -manipulations functions are : CONCAT, SUBSTR, INSTR, LENGTH, LPAD, TRIM
Number functions:
Number functions accept numeric input and return numeric input.
ROUND: rounds to the nearest unit of 100.
TRUNC: truncates the column, or value to n decimal places.
MOD: finds the reminder of the first argument divided by second argument. It is frequently used to determine whether a value is odd or even.
Date related functions:
Oracle's default date format is : DD-MON-RR. RR date is similar to YY but it also specify century. RR determines the default value for century in INSERT.
SYSDATE function:
 Returns current database server date and time. If your database in London and you are in California, it will display London current time. If you want California time use - CURRENT_DATE function. You can use arithmetic operators with SYSDATE function.
 Date-Manipulation functions : MONTHS_BETWEEN, ADD_MONTHS, NEXT_DAY,  ROUND, TRUNC, and LAST_DAY
Date function can be combined with Arithmetic function: date+number, Date-number, date-date, Date +number/24.
Data Type Conversion: 
TO_NUMBER, TO_DATE, TO_CHAR, TO_DATE 
Nesting Functions:
Nested functions are evaluated from deepest to the least deep level.
 Group functions : 
Group functions operates in multiple rows and gives a one result per group. Group functions ignores null values.  AVG, SUM, MIN, MAX, COUNT

    Database Related Interview Questions

    This is useful for advanced level Database Test Professional and Database Developer and DBA beginner. All questions-answers are based on Oracle Database Management System.

    1. What is a Database?
    An organized collection, storage of information.

    2. What is DBMS?
    To manage database, you need some type of system which, that system in Database Management System(DBMS). So, it is a program that stores, retrieves, and modifies data in database based on request.

    3. Name some types of databases.
    There are four main type of databases: hierarchical, network, relational, and object relational (this type is a new one).

    4. What is Data Models?
    It is a model developed before building a database system to explore the ideas, improve and understand overall database design. A data model should contains details for database developers, Database Administrators to build and maintain a database system.

    5. What is a unique identifiers(UID)?
    UID is any combination of attributes or relationships, or both that serves to distinguish entity. Each entity occurrence must be uniquely identifiable. Each attributes that is part of UID is tagged with #, secondary UID with(#).


    6.What is primary key and foreign key?
    here
    7. How do you operate relational database?
    By using SQL language. To access database, you can use SQL statements. There are other application programs and tools are also available. But these also use SQL language based on user's request.


    8. Tell me about different types of SQL statements.
    Data Manipulation Language(DML) ----- SELECT, INSERT,UPDATE,DELETE, MERGE
    Data Definition Language(DML) ----- CREATE, ALTER, DROP, RENAME, TRUNCATE, COMMENT
    Data Control Language(DCL)----- GRANT, REVOKE
    Transaction Control----- COMMIT, ROLLBACK, SAVEPOINT


    9. What is table join,  which SQL statement do you use to join tables?
    Joining brings together data that is stored in different tables by specifying the link between them. It helps to display data from multiple tables. SELECT statement is used to join tables.


    10. What is a Null value?
    If a row lacks a data value for particular column, that is called a null. Null value means value is unavailable or inapplicable. It is not a zero or blank space. Some constraints  like NOT NULL or PRIMARY KEY prevent null value being used in the column.


    11. What is Concatenation Operator?
    It is used to link columns to another columns, arithmetic  expressions, constant value to make a single output column. Operator sign is - || and it is used with select statement where output column name comes after AS keyword. For example:
    SELECT column1||column2 AS "OutputColumnName" from table


    12. What is a Literal Character Strings ?
    A literal is a character, a number, or a date that is included in a SELECT statement. It is not a column name or alias, it is something you use between || and || which will be displayed with query result. ' ' is used for date and character literal. It is used with select statement.


    13. What is 'Rules of Precedence'?
    It determines the order in which expression are evaluated and calculated. You can override the default order by using parentheses around the calculation that you want to calculate first.


    14.How do you display the Table structure?
    You can display table structure by using DESCRIBE command.It will display the column names, the data types and constraints(if any).


    15: what is SQL Function?
     here


    16: what is RR Date Format?
    It is the default date format of some database including Oracle.The default date format is: DD-MON-RR. RR date is similar to YY but it also specify century. RR determines the default value for century in INSERT.


    17. Explain about different types of joins in brief.
    Natural joins:The NATURAL JOIN clause is based on the all columns in the two tables that have the same name and data types.
    Self Join: Joins a table to itself.
    Nonequijoins: A join condition containing something other then an equality(=) operator.
    Outer Joins: returning results with no direct match.
      LEFT OUTER JOINS
      RIGHT OUTER JOINS
    CROSS JOINS


    18. What is a schema?
    A schema is a collection of objects such as table, views, indexes, clusters, stored procedures and database links. 


    19. What are the frequently used data-types in SQL(Oracle)?
    Some frequently used data-types are:

    Varchar2(max size specified) - Variable-length character data.
    char(size) - Fixed length character data.
    Number(precision, scale) - Variable-length numeric data.
    date, timestamp - date and time

    20 Tell me about database constraints.
    Database constrains are the restrictions, that prevents the invalid data entry to the table. Constraints enforces the rules on the data and constraints must be satisfied  for the any operation to be succeed
    PRIMARY KEY, UNIQUE, NULL, NOT NULL, FOREIGN KEY, CHECK are the major constraints. Constrains can be applied when creating a table or can be added later on with the alter statement.

    21. What is NOT NULL constraint ?
    NOT NULL constraint ensure that a NULL value is not permitted.




    What is Relational Databae Management System(RDBMS) ?

     A relational database is a collections of relations among two-dimensional tables. In this model, you create several tables to store pieces of information. There are operators/a set of operators that to produce the relations.
    In RDBMS,  Each row of data in a table is uniquely identified by a primary key and logically relate data from multiple tables using foreign key.

    Table: Employee
    Employee_ID First_Name Last_Name Department_ID
    101 Kobe Bryant 55
    102 Rhojan Rondo 50
    103 Ray Allan 45

    Table Name: Departments
    Department_ID_ID Dept Name Manager_ID
    10 LAL 4
    11 CEL 34
    11 CEL 4


     Data about different entities is stored in different tables.You may need to combined information from two tables to get a particular information. In RDBMS,  information is related by foreign keys that refers to the primary key in the same table or another table.
    Above, table 'Employees' contains information about employees and table 'Departments' contains information about departments. Department_ID which is Foreign Key in Employees  table is Primary Key in Departments.


    There are some rules/guidelines for assigning Primary Key and Foreign Key.
    You cannot use duplicate value in primary key
    Primary key generally cannot be changed
    Foreign key is based on data value and is a logical pointer.
    A foreign key must reference either a primary key or a unique value column.
    A foreign key value must match an existing primary key value or unique key value, otherwise it must be null.
    RDBMS are composed of objects or relations and are governed by constraints.

    Database Testing - Conceptual Understanding

    Have you ever think about what happens when you deposit any amount in your bank account?
    when you deposit amount, an event occurs, a program is executed and changes the database values according to event occurred in a corresponding way. It should not only add deposit to one table and not affect other relational tables.
    Basic theory is ACID, basic properties of a database transaction:

    Automaticity:
    An action must be either completed or aborted. The transaction cannot be partially successful. It must do ALL what it supposed to do or NOTHING. If one part of transaction fails entire the database transaction must be aborted.
    If the transaction successfully completes it is said to commit. The system is responsible for ensuring that all changes to the database have been saved. If the transaction does not successfully complete, it is said to abort. The system is responsible for undoing, or rolling back, all changes the transaction has made.

    Consistency:
    The transaction takes the resources from one consistent state to another. Application developer is also responsible who must make sure that all known integrity constraints are enforced by the application level as well. All integrity check, constraints, Rules, and triggers must be applied during transaction.

    Isolation:
    Transactions execute in sequence. Each one starts after the previous one completes. Execution of one transaction is not affected by the operations of another since they do not overlap in time. The execution of each transaction is isolated from all others. (Serial execution is inadequate from a performance perspective.)

    Durability:
    Changes made by the committed transaction are permanent, data should be changed permanently.

    A tester needs to think about capacity of database; size while deploying the QA box, how much data is there and how system is behaving with different size of data. Data mapping and Default data integrity are also important. (consistency). Now a days, Big business Software developments use OOP (Object Oriented Programming). Front end JAVA, C#, and back end Oracle, SQL Server. Another important aspect of RDBMS and OOP is related ‘object’. Mapping Objects to the relational DB based on relationship is one of the major tedious, but sensitive tasks. (Just a gist of data mapping, I am stopping this topic right here, because data mapping is a heavy weight topic and more relevant to talk within ETL).
    Compatibility is another big issue. Tester is not the one to decide about what is compatible with what; it should be more on project level than test level. But, a tester can do parallel testing, migration testing, etc. after migration to new version or after adding new system.

    Stored Procedure Testing:
    A SP needs to broken into action based on functionality and needs to be tested separately. A tester can write negative and positive test cases based on number of arguments, data types, orders of arguments, and return value and data type of return value being passed. People often consider it is difficult (being white box type) but. If there is an existing document explaining all these, SP test is not that complex. Of course knowledge of SQL language is vital.
    Other important aspects of Database testing are data type. Sometime developers mess up using same kind of data-type in front end and back end. A DB tester should make sure about it. Data type, size is also a performance related issue. It always make your marks as good tester if you to bring those issues during meetings. (if you are sure about what kind of Data-type  is right from business, performance and other technical point of view).
    Data-Driven Testing is a method to test many data with same script. Creating a script to provide data is an important task of a tester. There are many automation tools to create a capture and playback the script.


    Selenium Interview Queations-Answers



    For more interview question go to new blog - here


    What is Selenium?
    Selenium is a widely used automation tool for web based testing. It is easy to learn and use.

    What is Selenium 2.x?
    The NEXT GEN selenium. It is the Selenium Server-Webdriver replacing Selenium RC

    What is required?
    Basic knowledge of HTML, web based testing and web technologies is required. No other software development language is required. JAVA Script is nice to have.

    From where to download?
    Go to Selenium’s official site for all the information about it. You can download different version and mirror from its official site. which is -http://seleniumhq.org/

    Getting started with selenium.
    Selenium is a very good tool for Acceptance and Cross-Browser testing. It is also very useful for Functional testing. About how - Selenium has different components. Lets download selenium IDE’s latest version. Selenium IDE is a Firefox add-on, version 2+. Once it is download, you can record and play scripts in Firefox. I will talk in detail about how to use it in different section. for now lets download IDE, play around it and get familiar with most commonly used selenium commands. Selenium script is convertible in different development languages such and JAVA, C#, Pearl. With the help of Selenium-RC, user can run it different browsers and language environment.

    How to use selenium IDE?
     For now please go to http://seleniumhq.org

    What is the selenium's recording language?
    HTML

    What are the steps to run automation using selenium?
    The very basic steps are:
    1.  Record the test steps using selenium-IDE
    2. Modify the script according to the testing needs. Add validation points, Java Scripts, Time-out etc.
    3. Run the test
    4. View the result after test run complete analyze.

    Automation steps using Selenium C# language
    1.Record the Test Steps using selenium-IDE. Test will be recorded in HTML language
    2. Modify the script
    3. Convert the scripts into c# using selenium IDE
    4. Open the Visual Studio and create the test project there. Add a c# file
    5. Copy your c# script from Seleniun-IDE and paste into c# file you have created earlier. You can modify your script here as well such as adding if-else. This is the advantage of using other language.Call the Reporting file from here to store the result.
    6. Compile the code and debug if error occurs.
    7. Add the Compiles DLLs in NUNIT
    8. Run the test.
    9. Analyze the test result.

    What is Selenium Test Suite? how to develop it?
    Grouping test cases together as test suite is one of the major concept of software testing. In selenium, it is a HTML file that contains links of test cases. Test Runner is a Selenium IDE plug-in to run the test suite.


    What is SIDE?
    Selenium IDE


    How to run test case recorded using Selenium IDE in other browsers?
    With the help of Selenium -Remote Control


    What are three major parts, components of IDE?
    Command, Target, and Value


    How do you edit the recorded command in IDE?
    By selecting them and choosing the desired value from drop-down.

    What is the command to run selenium server from command prompt?
    Open the command prompt, CD to the folder (CD Command) having selenium server and run    command : java -jar selenium-server.jar

    What is the Selenium server default port number?
     4444

    How to run Selenium server, other than the default port 4444?
     java -jar selenium-server.jar -port