課程章節
培訓 · 第 2 單元:需求與驗證 · 第 2.5 章,共 6 章
2.5 驗證與測試中心 2:55
規劃每個需求的驗證方式、撰寫附步驟的測試案例,並加以執行。
展示 Holarch 2.13。
您將學到
- 為需求選擇驗證方法:檢查、分析、展示或測試
- 在測試中心規劃需求的驗證方法、層級與成功準則
- 建立測試套件,以及驗證某個需求且附有步驟的測試案例
- 執行測試並記錄其結果
規劃 Bike-Share Dock 的驗證:為每個需求設定方法、層級與成功準則,建立一個測試套件及驗證某個需求的測試案例,撰寫逐步程序,並在測試中心執行一次以記錄結果。
練習
在 Holarch 中於 CubeSat EO-1 示範專案上親自操作。
- 開啟您的 EO-1 示範專案(或建立它:管理專案 → 專案檔案 ▾ → 新增示範專案 → CubeSat(引導式系統工程))。
- 開啟驗證 → 測試中心,捲動到驗證涵蓋率。在 4.4 Downlink Encryption 上,確認 I 已開啟,在層級…下選擇子系統,並以 + 準則 新增成功準則。
- 按一下頁首的 + 新增 ▾ → 測試套件…,將它編號為
TS-4、命名為Mission Analyses,然後按一下建立。在其卡片上按一下 + 測試案例,將它命名為Daily Collection Volume Analysis,然後按一下驗證中的 + 來挑選 1.5 Daily Collection Volume(其方法為 Analysis,且尚無測試)。 - 輸入預期結果,然後按一下 + 步驟,新增兩個各有動作與預期結果的步驟,然後按一下套用。
- 在 TS-4 卡片上選擇 ⋯ → 執行週期…,記錄每個步驟,描述實際結果,然後按一下 ✔ 通過。
- 若要進行有檢查的逐步練習,請執行教學課程 9 Verify the Requirements(說明 → 教學課程)。
當 Daily Collection Volume Analysis 顯示 Passed 並附有您的姓名與日期,且 1.5 離開「未驗證」清單時,即完成。
自我檢查
- 對於 730 天任務壽命的需求,哪種方法合適?為什麼?
- 為什麼要在撰寫測試案例之前設定成功準則?
- 通過的測試案例會對它所驗證的需求造成什麼改變?
顯示答案
對於 730 天任務壽命的需求,哪種方法合適?為什麼?
Analysis:壽命在發射前無法量測,因此以計算來證明,例如可靠度估計。
為什麼要在撰寫測試案例之前設定成功準則?
它們陳述能證明需求已達成的可量測結果,讓測試針對該結果設計,而不是針對測試碰巧量測到的東西。
通過的測試案例會對它所驗證的需求造成什麼改變?
需求的驗證狀態會變為已驗證,並離開涵蓋率卡片與 RVTM 中的「未驗證」清單。
延伸閱讀
文字稿
顯示文字稿 (旁白與畫面內容)
Introduction
Chapter five: verification and the Test Center. A requirement is only met when someone shows it is met. Verification plans how, and the Test Center records what happened.
We plan and run the first test for the Bike-Share Dock.
Plan verification
There are four ways to verify a requirement. Inspection looks at the product. Analysis shows it by calculation or simulation. Demonstration shows it working, without measuring. And test measures it under controlled conditions.
On screen: Card: verification methods.
Open Verification, then Test Center. Requirement Verification Coverage lists every requirement that is not verified yet. For Pay at the Kiosk, the method is already Test. Set the level to System, and add success criteria: the measurable outcome that shows the requirement is met.
On screen: Test Center → coverage → Pay at the Kiosk → Level → + Criteria.
Show Available Bikes is easiest to verify by demonstration: show the kiosk displaying the numbers. Click D on its row.
On screen: Show Available Bikes → D.
Test cases
Tests live in suites. Click New, choose Test Suite, give it the number TS-1 and the name Kiosk Acceptance Tests, and click Create.
On screen: + New ▾ → Test Suite… → TS-1 Kiosk Acceptance Tests.
On the suite, click Test Case, and name it Card Payment Time Test. Then click the plus in its Verifies column, and pick Pay at the Kiosk.
On screen: + Test Case → name → Verifies + → 5.1.1.
Type the expected result, and add the procedure as steps: click Steps, add each step with its action and expected result, and click Apply.
On screen: Expected Result; + Steps → two steps → Apply.
Run
Now run it. Click Run Tests. The dialog shows the procedure, the steps and the expected result. Record each step, describe the actual result, and click Pass.
On screen: Run Tests → step results → actual result → Pass.
The result is recorded with the tester, the date and the steps, and the test case now shows Passed. Close the dialog.
On screen: Close → Passed.
Recap
Let's recap. You learned the four verification methods, planned a method, level and success criteria, created a suite and a test case that verifies a requirement, wrote its steps, and ran it.
Next, the verification matrices: the RVTM and the VCRM, in Holarch and in Word and Excel.