A Blog for quality professional

Archive for October, 2010

AJAX Testing with Selenium

The obvious approach approach in salenium  is to open the page, click the button, then check the value of the text field. However when we did that in Selenium, the test case failed.because its working on form submission

The reason for the test failure is perhaps not so obvious. What happens is that the asynchronous nature of the Ajax call means that the result doesn’t come back from the server immediately.

Selenium doesn’t know to wait for the result,so how can we get the effective Ajax effect tested

One way to solve the problem is to use the click and wait command instead of click; the “AndWait” suffix indicates that Selenium should wait for a page-reload.

This might seem like it would work, but there’s a catch: because the page is not reloaded, clickAndWait will make Selenium keep waiting forever. This clearly isn’t going to work.

Another possibility is to insert a pause between the click and aseertvalue So lets pause for 5 seconds in between, to give the server enough time to respond. This approach works most of the time, but it may fail if the server takes more than 5 seconds.

This might happen for any number of reasons, slow network, overloaded test machine, and so on. You can keep increasing the pause before checking the result, but this will make your tests run slower and slower. So this clearly isn’t the best solution because it’s not guaranteed to work and makes your tests run much slower than necessary.

Fortunately Selenium has provided support for doing exactly what we want. When a field value changes in the current page, you can use the waitForValue command to make Selenium wait until the expected value

So in order to make the failing test pass we need to replace the failing assertvalue command.

When executing this command, Selenium will suspend the execution of current test case and wait for the expected value. When the string “newValue” appears in the text field, the suspended test will go on. One thing to note: if you misspelled the expected value, Selenium will wait for 30 seconds before timing out.

As you may have already guessed, there are lots more commands that can be used to test Ajax effects. For example, if you want to check some plain text updated with Ajax, there’s waitForText ; if you want to check the title of current page, there’s waitForTitle if you want to verify that an HTML element is removed, there’s waitForElementNotPresent.

Idea Taken from popular site and my own experience

Shishir Gopal Jee Srivastava

Cost Of Qualty

Cost of Quality (“COQ”)  is a measurement used for assessing the waste or losses from some defined process (eg. machine, production line, plant, department, company, etc.).

Cost of Quality (“COQ”) is measured in currency (eg. $), requiring all losses and wastes to be converted to their liquidated cost equivalent (ie. man-hrs lost or spent are converted to $ by multiplying by the hourly rate, $/hr).

PQA has developed numerous proprietary Cost of Quality (“COQ”) systems for ensuring the effectiveness of Cost of Quality (“COQ”) implementations.

COQ Category Typical Descriptions (may vary between different Organizations) Examples
Internal Costs associated with internal losses (ie. within the process being analyzed) off-cuts, equipment breakdowns, spills, scrap, yield, productivity
External Costs external  the process being analyzed (ie. occur outside, not within).  These costs are usually discovered by, or affect third parties (eg. customers).  Some External costs may have originated from within, or been caused, created by, or made worse by  the process being analyzed.  They are defined as External because of where they were discovered, or who is primarily or initially affected. customer complaints, latent defects found by the customer, warranty
Preventive Costs associated with the prevention of future losses:   (eg. unplanned or undesired problems, losses, lost opportunities, breakdowns, work stoppages, waste, etc.) planning, mistake-proofing, scheduled maintenance, quality assurance
Assessment Costs associated with measurement and assessment of the process. KPI’s, inspection, quality check, dock audits, third party audits, measuring devices, reporting systems, data collection systems, forms

Cost of Quality (“COQ”) can be used to identify the global optimum for a process, and monitor that process’ progress towards its global optimum.  Global optimum is defined as the best possible outcome from all physically possible operating modes, combinations, and permutations of the current process.

For info on $ losses typical associated with organizations and their quality levels

Cost of Quality (“COQ”) is used to collect cost data on a sampling basis (eg. all data occurring during a 24 hr period, calculated once each quarter), or on a continuous basis (eg. Cost of Quality (“COQ”) is calculated with all data occurring in the month, and reported monthly) .

After confirming that the data is accurate and comprehensive, and consistent with previous definitions and implementations, it is analyzed for opportunities and trends.  Based upon statistical analysis (eg. regression analysis, indexes, correlations, Pareto analysis, factor analysis, etc.), conclusions and recommendations are presented to managers of the process being analyzed.

In some cases (supported by process modeling, heuristics, prior experience, or intuition) the optimum Cost of Quality (“COQ”) can be predicted, and the process design necessary for achieving this global optimum Cost of Quality (“COQ”) can be defined.  A plan can then be defined to modify the current process, phase by phase, so as to move towards this global optimum process.

Management responsible for the process can decide on if, how, and when they will run the current process, or modify the process for even better results.

All projects are analyzed for their impact on Cost of Quality (“COQ”), and projects that show high ROQ are implemented on a priority basis
(ROQ%= $Cost of Quality (“COQ”) savings/$Implementation cost*100%).

When all costs are included, Cost of Quality (“COQ”) as a % of gross sales $ will probably be around 30% to 35% for a profit orientated organization, 40% to 60% for a not-for-profit organization (ie. hospitals, charities, government, etc.).  Many organizations take only a sub-set of the costs, including only those that tend to fluctuate, or that often need management intervention.  The others are assumed to be constant.

When manufacturing companies often earn only 5% NPBT (Net Profit Before Tax), a 35% Cost of Quality (“COQ”) indicates that 40% of gross revenue is generated by the company as profit, but only 5% of that gets trapped as NPBT.  Therefore, the profit yield is only 12.5% (87.5% of the available profit is lost before it gets to the bank).

For improvements in Cost of Quality (“COQ”), some manufacturers have been able to reduce manufacturing costs by as much as 7.65% per year, every year, for more than 10 years.

For Six Sigma processes, Cost of Quality (“COQ”) is usually reduced to less than 1% of gross sales $.   This indicates that, as large and unbelievable as Cost of Quality (“COQ”) $ seems to most managers, it is a real number that can be eliminated through hard work and dedication.


Obviously, as more and more improvements are made, it becomes more difficult to find the next saving.  This is when an excellent Cost of Quality (“COQ”) system can help point out the remaining opportunities.


For organizations that:

  • Currently have no Cost of Quality (“COQ”) system, but could benefit from a well-designed & implemented Cost of Quality (“COQ”) system
  • Have a Cost of Quality (“COQ”) system, but that Cost of Quality (“COQ”) system is poorly designed, or poorly implemented.

the following symptoms are typically felt:

  • Slow rate of improvement
  • Low or no profitability
  • Bureaucracy or complexity of business processes continue to get worse and worse
  • Changes in one area tend to have disastrous effects in other areas
  • Management get personally involved in quality problems only during a major crisis
  • Management is running out of ideas on where to cut costs any further
  • All employees are not actively and personally involved in driving the Organization’s Mission forward
  • Many individuals and departments disagree on what are the top priorities for the Organization
  • Sub-processes and Departments are operated in a manner that is detrimental to the Organization’s overall best interest.
  • For organizations not using COQ Software, there are often higher costs for running the COQ system, inconsistent implementation, and non-optimum results from the COQ system.

Problem Encountered

Because of poor design or poor implementation of Cost of Quality (“COQ”) systems, the Cost of Quality (“COQ”) systems often suffer from one or more of the following problems:

  • COQ data collection is watered-down, or have superficial implementations that quickly become make-work exercises with little or no benefit, other than to fill filing cabinets or hard disk drives on computers.
  • Efforts are directed at where it is easy to collect data, or easy to implement changes, instead of focusing on the Cost of Quality (“COQ”) priorities (eg. largest cost category, most variation, largest business risk, etc.)
  • The Cost of Quality (“COQ”) input data are often incomplete.  The Cost of Quality (“COQ”) definitions are often un-clear, or not fully understood, resulting in varying interpretation and implementation over time.  This variability tends to add significant noise to the Cost of Quality (“COQ”) data, clouding the interpretation and hiding significant trends for extended periods of time.
  • Management does not actively use the Cost of Quality (“COQ”) data in an effective manner.  Decisions are often made without realizing nor considering the impact on Cost of Quality (“COQ”), thereby neutering the Cost of Quality (“COQ”) system to irrelevancy.
  • When Cost of Quality (“COQ”) is not utilized during project approval decisions, as management makes changes (supposed “improvements”), Cost of Quality (“COQ”) $ tend to shift from one category to another, with little net effect.  For example, a new machine is purchased to reduce scrap.  Higher setup, first-off, inspection, and maintenance costs offset the scrap savings, with no net improvement in Cost of Quality (“COQ”).
  • Cost of Quality (“COQ”) costs oscillate between the four Cost of Quality (“COQ”) categories on a revolving basis, with little or no reduction in the total Cost of Quality (“COQ”).  For example, money is spent to increase surveillance, which indicates a problem exists with internal &/or external failure costs.  Surveillance costs are stopped, but prevention actions are taken to reduce failure costs, thereby increasing prevention costs.  The preventive actions are not comprehensive or not consistently implemented, so the internal and/or external failures eventually come back.  The rising internal &/or external failures prompt another round of surveillance activities, with additional assessment costs incurred.
  • The collection of Cost of Quality (“COQ”) data becomes more and more costly and bureaucratic over time, making it slower to respond to significant changes, and less useful.
  • Statistical analysis of Cost of Quality (“COQ”) data is not performed.  Early recognition of trends are missed, and random variations are mistaken for significant signals; starting “wild goose” chases, wasting time & resources, and distracting everyone from the real issues.
  • Cost of Quality (“COQ”) system is isolated from other KPI (Key Performance Indicators) systems, missing the opportunity for more in-depth understanding of cause-effect relationships for the Cost of Quality (“COQ”) results.
  • For any measurement system, it should cost less than ~1% of the savings generated by the use of the measurement.

Consideration before Implementing COQ

  1. Is the management team committed to making rapid changes for maximum profitability, within the imposed constraints (eg. Company’s Mission, laws & regulations, stakeholder satisfaction, etc.)?
  2. Are there “sacred cows”, legacy systems, departmental silos, and empire building that are exempt from re-evaluation?
  3. Are the hard costs (payroll, raw materials, utilities, etc.) more easily measured (or more important) than the soft costs (morale, employee satisfaction, market share, plant capacity utilization, customer’s losses, supplier’s losses, societal losses)?
  4. Are the current management measurement systems (eg. KPI’s, scrap, rework, excess freight charges, stock outages, absenteeism, productivity, profitability, etc.) compatible with Cost of Quality (“COQ”)?  Can these other systems be adapted to include Cost of Quality (“COQ”) without neither duplication nor conflict?
  5. Will people be receiving mixed messages and conflicting signals between Cost of Quality (“COQ”) and the traditional management measurements?
  6. Is there management commitment to do something about the Cost of Quality (“COQ”) data on a timely basis?

Verifying the closure of bugs

When a product gets completed, it is released for testing to QC department along with the relevant documents. The QC department based on the scope of testing, availability of testers and the time at which the product is estimated to be released to customer, prepares its test plan. After studying the business and customer requirements, test cases and test scenarios are built by testers, based on which bugs or defects are reported. Once the bugs report (or defects report) is released to development team by the testing team, it is the development team that comes into the action. They based on the category, validity of a bug divide among themselves the bugs to be fixed and inform the testing team the estimated time required to close or address all the bugs/ defects. Once all the defects are fixed, the product goes back to testing team, for verification of closure of bugs.

M.K. Gandhi

Mohandas Karamchand Gandhi was a man considered one of the great sages and prophets. He was held as another Buddha, another Jesus, Indians called him the ‘Father of the Nation’. They showered their love, respect and devotion on him in an unprecedented measure. They thronged his way to have a glimpse of him, to hear one world from his lips. They applied on their foreheads the dust on the path he had trodden. For them, he was almost an incarnation of God, who had come to break the chains of their slavery. The whole world bowed to him in reverence. Even his opponents held him in great respect.

Mohandas Gandhi was, however, not a great scholar, nor was he a great warrior. He was not born with exceptional faculties. Neither was he a good orator, nor a great writer. He did not claim anything exclusively divine in him. He did not claim being a prophet or having superhuman powers. He considered himself an average man with average abilities. Born in a middle class Bania family in an obscure princely State in a corner of India, he was a mediocre student, shy and nervous. He could not muster courage to speak in public. His first attempt at legal practice miserably failed.
But he was a humble seeker of Truth. He was a man with exceptional sincerity, honesty and truthfulness. For him, understanding meant action. Once any principle appealed to him, he immediately began to translate that in practice. He did not flinch from taking risks and did not mind confessing mistakes. No opposition, scorn or ridicule could affect him. Truth was his sole guiding star. He was ever-growing; hence he was often found inconsistent. He was not concerned with appearing to be consistent. He preferred to be consistent only with the light within.

He sacrificed his all and identified himself with the poorest of the poor. He dressed like them, lived like them. In the oppressed and the depressed people, he saw God. For him, they too were sparks of the divine light. They might not have anything else, but they too had a soul. For Gandhi, soul-force was the source of the greatest power. He strove to awaken the soul-force within himself and within his fellowmen. He was convinced that the potentialities of the soul-force have no limit. He himself was a living example of this conviction. That is why this tiny and fragile man could mobilise the masses and defeat the mighty British empire. His eleven vows, his technique of Satyagraha, his constructive programme – all were meant to awaken and strengthen the soul-force. He awakened and aroused a nation from semi-consciousness. It was a Herculean task. For, India was not a united country, it was a sub-continent. It was a society divided in different classes, castes and races, in people with different languages, religions and cultures.

It was a society where almost half of the population i.e., women, was behind purdah or confined to the four walls of houses, where one-fourth of the population – the depressed classes – was living marginalised life, where many did not have a single full meal every day. Gandhi made the oppressed sections wake up and break their chains. He mobilised the people and united them to work for the cause of Swaraj, which gave them a sense of belonging, a sense of purpose. Gandhi wanted to win Swaraj for the masses. For him, Swaraj did not mean replacement of White masters by brown masters. Swaraj meant self-rule by all. He said: ”Real Swaraj will come, not by the acquisition of the authority by a few, but by the acquisition of the capacity by all to resist authority when it is abused.” He worked to develop such a capacity. Development of such a capacity involved transformation of the individual.

Transformation of the individual and transformation of the society – they were not separate, unrelated things for Gandhi. Revolutionary social philosophies had concentrated on changing the society. On the other hand, spiritual seekers had concentrated on the inner change. Gandhi not only bridged the gap between these extremes, he fused them together. Gandhi was thus both a saint and a social revolutionary. For Gandhi, unity of life was great truth. His principle of non-violence stemmed from this conviction. Non-violence was not a matter of policy for him; it was a matter of faith. He applied the doctrine to all the departments of individual and social life and in so doing revolutionized the doctrine, made it dynamic and creative. He believed that a true civilization could be built on the basis of such non-violence only.
He rejected the modern civilization. For him, it was a disease and a curse. This civilization leads to violence, conflicts, corruption, injustices, exploitation, oppression, mistrust and a process of dehumanisation. It has led the world to a deep crisis. The earth’s resources are being cornered by a handful of people without any concern for others and for the coming generations. The conventional energy sources are getting depleted. Forests are being destroyed. Air, water, soil-everything has been polluted.

We are living under the shadow of nuclear war and environmental disasters. Thinking men the world over are looking to Gandhi to find a way out of this crisis and to build an alternative model of sustainable development. Gandhi knew that the earth has enough to satisfy everybody’s need but not anybody’s greed. He had called for the replacement of greed with love. Gandhi is, therefore, now a source of inspiration and a reference book for all those fighting against racial discrimination, oppression, domination, wars, nuclear energy, environmental degradation, lack of freedom and human rights- for all those who are fighting for a better world, a better quality of life. Gandhi is, therefore, no longer an individual. He is a symbol of all that is the best and the most enduring in the human tradition. And he is also a symbol of the alternative in all areas of life-agriculture, industry, technology, education, health, economy, political organisations, etc. He is a man of the future – a future that has to be shaped if the human race has to survive and progress on the path of evolution

offshore outsource

Offshore outsourcing, a type of business process outsourcing (BPO), is the exporting of IT-related work from the United States and other developed countries to areas of the world where there is both political stability and lower labor costs or tax savings. Outsourcing is an arrangement in which one company provides services for another company that could also be or usually have been provided in-house. Offshore simply means “any country other than your own.” The Internet and high-speed Internet connections make it possible for outsourcing to be carried out anywhere in the world, a business trend economists call globalization. In general, domestic companies interested in offshore outsourcing are not only trying to save money in order to be more price-competitive against each other, but also to enable them to compete with businesses in other countries.

Critics of offshore outsourcing worry that if too much IT-related work is farmed out to other countries, home-grown IT talent will “dry up.” They point out that once a company begins outsourcing overseas, they will find it difficult to reverse the trend and justify paying more in salaries, taxes, and job benefits for the same work they used to outsource. Proponents maintain that the judicious use of offshore outsourcing will help make all IT workers become more productive and allow companies to develop more agile and responsive business models, which in turn, will raise salaries for domestic workers in all countries.

According to the IT research and analysis firm Gartner, by the year 2004 more than 40% of IT-related businesses will either be investigating the possibility of offshore outsourcing or will have already shipped some IT-related work overseas

Tag Cloud