(1) What type of faults can occur in Ajax applications that do not occur in other types of web applications? What techniques can be used to detect these Ajax specific faults? Ans. The two common type of faults that can occur in Ajax Web applications than in other kinds of applications, the faults associated with the following features: i. Asynchronous messages and ii.DOM manipulation Due to asynchronous messages Ajax programmers cannot make the assumption that each server response comes immediately after the request, with nothing occurring in-between. When the network performance degrades, we may observe unintended interleaving of server messages, swapped callbacks etc. DOM manipulation, for example deriving from assumptions about the DOM structure which become invalid during the execution because of page manipulation by Javascript code or an inconsistency between code and DOM, which makes the code reference an incorrect or nonexistent part of the DOM, causes executions occurring under incorrect DOM state. As described in the slides, an FSM is used to detect the specific faults. (2) Describe briefly Ajax architecture. Show how asynchronous messages help improving user experience in a typical Ajax application. Ans. Ajax (Asynchronous Javascript And XML) is a group of technologies having i. HTML and CSS for information presentation. ii. The Document Object Model to access and modify the displayed information. iii. The XMLHttpRequest object to retrieve data from the web server asynchronously. iv. XML to wrap data v. Javascript code to bind everything together. The Ajax object XMLHttpRequest wraps any service request or data travelling between client and server. The asynchronous response from the server is handled at the client side by Javascript code which is part of a callback triggered by the response. Upon arrival of the server message, the handler method associated with such an event is run. Depending on the received data, the message handler can change the structure or content of the current web page through the DOM. The main technological novelty of Ajax is the asynchronous communication between client and server, combined with the reflection mechanism provided by the DOM, which allows updating parts of the current Web page without resending the entire page. The synchronous request-response protocol used by traditional Web applications introduces a delay between one page and the next one, which prevents all interactions requiring a short response time. On the contrary, Ajax applications are based on asynchronous requests, which leave the user interface active and responsive. (3) What is the importance of semantically interacting events? Ans. When the result of two events executed together is different than executed in isolation, the two events are semantically interacting. We can use this relationship for test case reduction. By considering only semantically interacting events, we expect not to loose too much in terms of fault revealing capability of the test suite, since we are retaining all paths involving semantic interactions between events.