| CPC G06F 11/3684 (2013.01) | 30 Claims |

|
1. A method for (1) constructing a test script from a test case and a time-evolving model of an application, the time-evolving model including a set of translations and a state machine, in which states correspond to pages of the application and edges correspond to actions that are performed to transition from one of the pages to another one of the pages of the application or are performed within one of the pages, and (2) updating the time-evolving model of the application, the method comprising:
(a) initializing a variable to store an ordered list of translations;
(b) receiving the test case;
(c) segmenting the test case into an ordered list of test case segments;
(d) navigating to a current application window of the application;
(e) assigning an initial test case segment in the ordered list of test case segments as a current test case segment;
(f) based on a collection of application elements present in the current application window, determining whether a first state exists in the state machine that corresponds to the current application window;
(g) if the first state does not exist, creating a new state that is defined by the collection of application elements present in the current application window, modifying the state machine to incorporate the new state, and assigning the new state as a current state;
(h) if the first state exists, assigning the first state as the current state;
(i) attempting to determine a current action that originates from the current state and corresponds to the current test case segment;
(j) if the current action cannot be determined, aborting the method for constructing the test script;
(k) if the current action is determined, appending a translation to the ordered list of translations, the translation including a mapping between the current action and the current test case segment, and executing the current action in the current application window to navigate to a subsequent application window;
(l) determining whether a subsequent test case segment exists in the ordered list of test case segments;
(m) if the subsequent test case segment exists in the ordered list of test case segments, assigning the subsequent application window as the current application window, assigning the subsequent test case segment as the current test case segment, and repeating steps (f) through (m) until the method for constructing the test script has been aborted or no subsequent test case segment exists in the ordered list of test case segments; and
(n) if the subsequent test case segment does not exist in the ordered list of test case segments and the method for constructing the test script has not been aborted, generating the test script based on respective actions contained within the ordered list of translations and executing the test script on the application.
|