Monday, May 23, 2011

Statement Coverage, Branch / Decision coverage and Path coverage

Statement Coverage: Check if each statement in the code has been executed at least once
Branch / Decision coverage: Check if each possible branch from a decision point has been executed at least once
Path coverage: Check if every possible path is executed at least once.

Example:
READ P, Q
IF P+Q > 100 THEN
PRINT 'LARGE'
END IF
IF P>50
PRINT 'P Is Greater'
END IF

Draw flow diagram for this code:

Statement coverage: We need 1 test case to cover all the statements in the code

Branch/Decision coverage: We need 2 test case to cover all the branches in the code

Path coverage: We need 4 test case to cover all the paths in the code

15 comments:

  1. Replies
    1. Big data is a term that describes the large volume of data – both structured and unstructured – that inundates a business on a day-to-day basis. big data projects for students But it’s not the amount of data that’s important.Project Center in Chennai

      Spring Framework has already made serious inroads as an integrated technology stack for building user-facing applications. Corporate TRaining Spring Framework the authors explore the idea of using Java in Big Data platforms.

      Spring Training in Chennai

      The new Angular TRaining will lay the foundation you need to specialise in Single Page Application developer. Angular Training

      Delete
  2. It is really a great work and the way in which u r sharing the knowledge is excellent.Thanks for helping me to understand basic concepts. As a beginner in software testing your post help me a lot.Thanks for your informative article. software testing Training in chennai | Best software testing Training institute in velachery

    ReplyDelete
  3. Awesome post.
    I read your blog everything is helpful and effective.
    Thanks for sharing with us.
    Software Testing Training in Bangalore

    ReplyDelete
  4. Nice post about Software Testing Training in Chennai software testing training. Kindly provide more update about Selenium training ( C#, Python, Java)

    ReplyDelete
  5. Really nice topics you had discussed above. I am much impressed. Thank you for providing this nice information here

    Software Testing Company

    QA Services

    Performance Testing

    Game QA

    ReplyDelete
  6. I was very interested in the article , it’s quite inspiring I should admit. I like visiting your site since I always come across interesting articles like this one. Keep sharing! Regards. Read more about Software Testing Services
    Software Qa Services

    ReplyDelete
  7. Wow its a very good post. The information provided by you is really very good and helpful for me. Keep sharing good information.

    Best Training Institute in Bangalore BTM. My Class Training Bangalore training center for certified course, learning on Software Training Course by expert faculties, also provides job placement for fresher, experience job seekers.
    Software Training Institute in Bangalore

    ReplyDelete
  8. Very interesting, good job and thanks for sharing such a good blog. Thanks a lot…

    Learn Hadoop Training from the Industry Experts we bridge the gap between the need of the industry. Softgen Infotech provide the Best Hadoop Training in Bangalore with 100% Placement Assistance. Book a Free Demo Today.
    Big Data Analytics Training in Bangalore
    Tableau Training in Bangalore
    Data Science Training in Bangalore
    Workday Training in Bangalore

    ReplyDelete
  9. Thanks for sharing such a great information..Its really nice and informative..... software testing tutorial

    ReplyDelete
  10. Pretty good post. I just stumbled upon your blog and wanted to say that I have really enjoyed reading your blog posts. Any way I'll be subscribing to your feed and I hope you post again soon.
    Software Testing Training in Chennai | Software Testing Training in Anna Nagar | Software Testing Training in OMR | Software Testing Training in Porur | Software Testing Training in Tambaram | Software Testing Training in Velachery

    ReplyDelete