System and method for providing code coverage

US2016328314A1 · US · A1

Patent metadata
FieldValue
Publication numberUS-2016328314-A1
Application numberUS-201615079595-A
CountryUS
Kind codeA1
Filing dateMar 24, 2016
Priority dateMay 6, 2015
Publication dateNov 10, 2016
Grant date

How to read this patent

A practical reading order for non-experts. Skip the full description unless you need deep technical detail.

  1. Title

    What the patent document calls the invention.

  2. Abstract

    A short plain-language summary of the technical disclosure.

  3. Assignees and inventors

    Who owns or filed the patent and who is credited as inventor.

  4. Key dates

    Filing, priority, publication, and grant dates set the timeline.

  5. First independent claim

    The legal scope of protection — read this for what is actually claimed.

  6. CPC / IPC classifications

    Technology tags used to group this patent with similar filings.

  7. Citations and related patents

    Prior art links and similar publications in this corpus.

Abstract

Official abstract text for this publication.

Disclosed is a method and system for providing code coverage of a code. The system may determine a type of file comprising the code. The system may extract a source code from the code, based on the type of file. The system may process the source code for generating a structured source code. The system may determine code coverage of the structured source code by executing test cases upon the structured source code. The system may provide a code coverage report comprising line coverages, program coverages, and code block coverages of the structured source code.

First claim

Opening claim text (preview).

We claim: 1 . A method for providing code coverage of a code, the method comprising: determining, by a processor, a type of file comprising a code; extracting, by the processor, a source code from the code based on the type of file, wherein the source code is extracted using a parser; processing, by the processor, the source code for generating a structured source code; creating, by the processor, code blocks indicative of a portion of the structured source code, based on a type of declaration of statements, functions, and sub-functions; determining, by the processor, code coverage of the structured source code by executing test cases upon the structured source code; and providing, by the processor, a code coverage report comprising line coverages, program coverages, and code block coverages of the structured source code. 2 . The method of claim 1 , wherein the type of file comprises at least one of JavaScript, HTML pages, CSHTML pages, internal user controls, partial views, master pages, Java Server Pages (JSP), Cascading Style Sheets (CSS), Active Server Page Extended (ASPX) file, ASCX file and Extensible Markup Language (XML) resources. 3 . The method of claim 1 , wherein the parser comprises at least one of a generic parser and a Hyper Text Markup Language (HTML) parser. 4 . The method of claim 1 , wherein the source code is present in at least an inline file, an embedded form, and an external dedicated file. 5 . The method of claim 1 , further comprising instrumenting the source code for adding test codes into the functions of the structured source code. 6 . The method of claim 1 , further comprising determining intermediate code block coverage for browser based applications by adding analytical script to web pages. 7 . The method of claim 1 , further comprising determining code block coverages of the code blocks by mapping the code coverage of program lines with the code blocks. 8 . The method of claim 1 , further comprising identifying redundant test data by using the code coverage report. 9 . The method of claim 1 , further comprising performing test impact analysis by mapping the test cases with the code blocks and modified code blocks of the code. 10 . The method of claim 1 , further comprising storing program coverages and the code blocks and the code coverage in an incremental manner. 11 . The method of claim 1 , further comprising determining the code coverage of a distributed web application deployed at a remote location by using a test agent exposing a service end point. 12 . A system for providing code coverage of a code, the system comprises: a processor; and a memory coupled to the processor, wherein the processor is capable for executing programmed instructions stored in the memory to: determine a type of file comprising a code; extract a source code from the code based on the type of file, wherein the source code is extracted using a parser; process the JavaScript source code for generating a structured source code; create code blocks indicative of a portion of the structured source code, based on a type of declaration of statements, functions, and sub-functions; determine code coverage of the source code by executing test cases upon the structured source code; and provide a code coverage report comprising line coverages, program coverages, and code block coverages of the structured source code. 13 . The system of claim 12 , wherein the type of file comprises at least one of JavaScript, HTML pages, CSHTML pages, internal user controls, partial views, master pages, Java Server Pages (JSP), Cascading Style Sheets (CSS), Active Server Page Extended (ASPX) file, ASCX file and Extensible Markup Language (XML) resources. 14 . The system of claim 12 , wherein the parser comprises at least one of a generic parser and a Hyper Text Markup Language (HTML) parser. 15 . The system of claim 12 , wherein the source code is present in at least an inline file, an embedded form, and an external dedicated file. 16 . The system of claim 12 , further comprising instrumenting the JavaScript for adding test codes into functions of the structured source code. 17 . The system of claim 12 , further comprising determining intermediate code block coverage for browser based applications by adding analytical script to web pages. 18 . The system of claim 12 , further comprising determining code block coverages of the code blocks by mapping the code coverage of program lines with the code blocks. 19 . The system of claim 12 , further comprising identifying redundant test data by using the code coverage report. 20 . The system of claim 12 , further comprising performing test impact analysis by mapping the test cases with the code blocks and modified code blocks of the code. 21 . The system of claim 12 , further comprising storing program coverages and the code blocks and the code coverage in an incremental manner. 22 . The system of claim 12 , further comprising determining the code coverage of a distributed web application deployed at a remote location by using a test agent exposing a service end point. 23 . A non-transitory computer readable medium embodying a program executable in a computing device for providing code coverage of a code, the program comprising: a program code for determining a type of file comprising a code; a program code for extracting a source code from the code based on the type of file, wherein the source code is extracted using a parser; a program code for processing the source code for generating a structured source code; a program code for creating code blocks indicative of a portion of the structured source code based on a declaration of statements, functions, and sub-functions; a program code for determining code coverage of the structured source code by executing test cases upon the structured source code; and a program code for providing a code coverage report comprising line coverages, program coverages, and code block coverages of the structured source code.

Assignees

Inventors

Classifications

Patent family

Related publications grouped by family.

External sources

Frequently asked questions

Answers are generated from the same data shown on this page.

What does patent US2016328314A1 cover?
Disclosed is a method and system for providing code coverage of a code. The system may determine a type of file comprising the code. The system may extract a source code from the code, based on the type of file. The system may process the source code for generating a structured source code. The system may determine code coverage of the structured source code by executing test cases upon the str…
Who is the assignee on this patent?
Hcl Technologies Ltd
What technology area does this patent fall under?
Primary CPC classification G06F11/3676. Mapped technology areas include Physics.
When was this patent published?
Publication date Thu Nov 10 2016 00:00:00 GMT+0000 (Coordinated Universal Time) (A1). Legal status and post-grant events are not shown on this page.
What related patents are in patentsdb?
We list 3 related publications on this page (citations in our corpus or others sharing the same primary CPC).