【正文】
五個端口輸入事件覆蓋指標: ? PI1: each port input event occurs ? PI2: mon sequences of port input events occur ? PI3: each port input event occurs in every “relevant” data context ? PI4: for a given context, all “inappropriate” input events occur ? PI5: for a given context, all possible input events occur 處理與語境有關的端口輸入事件,是物理輸入事件 與課程有關的問題 2022machunyan 西北工業(yè)大學軟件與微電子學院 端口輸出事件定義的覆蓋指標 ? PO1: each port output event occurs. ? PO1 is acceptable minimum especially when a system has a rich variety of output messages for error conditions. ? PO2: each port output event occurs for each cause. ? PO2 is good but hard to quantify ? Basically it refers to threads that interact with respect to a port output event. ? Usually a given port output event has a small number of causes. 與課程有關的問題 2022machunyan 西北工業(yè)大學軟件與微電子學院 基于端口的線索測試 ? 是基于事件測試的有用補充 ? 通過基于端口的測試,對于每個端口都要詢問端口上會出現(xiàn)什么事件 ? 根據每個端口的事件列表尋找使用輸入端口和輸出端口的線索 ? 對于端口設備來自外部提供商的系統(tǒng)特別有用 ? 從 E/R模型可看出,設備和事件之間的多對多測試應該在兩個方向上進行 ? 基于事件的測試覆蓋從事件到端口的一對多關系,反之,基于端口的測試覆蓋從端口到事件的一對多關系 與課程有關的問題 2022machunyan 西北工業(yè)大學軟件與微電子學院 基于數據的線索測試 ?基于端口和基于事件的測試適合主要以事件驅動的“反應式”系統(tǒng) ? 因為這些系統(tǒng)要對激勵(端口輸入事件)做出響應,并且反應常常以端口輸出事件的形式做出 ? 反應式系統(tǒng)的兩個特征:長時間運行和維持與環(huán)境的關系 ?一般地,事件驅動的反應式系統(tǒng)沒有有意思的數據模型,因此基于數據模型的線索不是特別有用 與課程有關的問題 2022machunyan 西北工業(yè)大學軟件與微電子學院 基于數據的線索測試(續(xù)) ?非反應式系統(tǒng)是典型的“靜態(tài)”,因而是轉換式系統(tǒng) ? 支持以數據庫為基礎的事務處理,一般采用 E/R 模型描述 ?定義基于數據的覆蓋指標 描述線索集合 ? 關系中的信息一般包含在系統(tǒng)級線索中,而實體中的線索一般局限于單元級 與課程有關的問題 2022machunyan 西北工業(yè)大學軟件與微電子學院 基于數據的線索測試(續(xù)) ?定義下列覆蓋: ? DM1: exercise the cardinality of every relationship . ? DM2: exercise the participation of every relationship . ? DM3: exercise the functional dependencies among relationships 與課程有關的問題 2022machunyan 西北工業(yè)大學軟件與微電子學院 ? DM2: ? ensure where or not every instance of an entity participates in a relationship. ? Some modeling techniques express participation in numerical limits (. OMT, “at least one and at most 12”). ? When available, this information leads to boundary value system threads. ? DM3: ? it may be possible to determine explicit logical connections among relationships = functional dependencies as in relational databases. ? These are reduced when the database is normalized, but they still exist and lead to interesting test threads. 與課程有關的問題 2022machunyan 西北工業(yè)大學軟件與微電子學院 系統(tǒng)測試指導方針 ?偽結構系統(tǒng)測試 ?運行剖面 ?累進測試和回歸測試 與課程有關的問題 2022machunyan 西北工業(yè)大學軟件與微電子學院 偽結構系統(tǒng)測試 ? At the system level we can use graph based metrics as a cross check on the functional threads. ? The claim is for pseudostructural testing since the node and edge coverage metrics are defined in terms of a control model of a system and not directly derived from the system implementation. ? Behavioral models are only an approximation to the system’s reality: ? why it is possible to depose the models to several levels of detail. ? A true structural model’s sheer size and plexity would make it too cumbersome to use. 與課程有關的問題 2022machunyan 西北工業(yè)大學軟件與微電子學院 ? Decision tables and FSMs are good choices for ASF testing. For example: ? If an ASF is described using a decision table, conditions usually include port input events, and actions are port output events ? It is possible to devise test cases that cover every condition, every action, or most pletely, every rule. ? As in FSMs, test cases can cover every state, transition or every path. 與課程有關的問題 2022machunyan 西北工業(yè)大學軟件與微電子學院 運行剖面 ? Many aspects of testing can be related to the old 80/20 rule: ? for a system with many threads, 80% of the execution traverses only 20% of the threads. ? The basic concept in testing: ? execute test cases such that when a failure occurs, the presence of a fault is revealed. ? The distribution of faults is only indirectly related to the reliability of the system. 與課程有關的問題 2022machunyan 西北工業(yè)大學軟件與微電子學院 ? Simple view of reliability: ? The probability that no failures occur during a specific time interval. ? If faults are in less traveled threads of system, ? then reliability will appear higher than if the same number of faults were in the high traffic areas. ? Operational profiles: ? Determine the execution frequencies of various threads, then select threads accordingly. ? Operational profiles maximize the probability of finding faults by inducing failures in the most frequently traversed threads. 與課程有關的問題 2022machunyan 西北工業(yè)大學軟件與微電子學院 System Testing Categories ? Objective of system testing: ? To verify whether the implementation (or system) conforms to the requirements as specified by the customer