在軟體開發的過程當中,為了修復或是增加功能工程師會不斷的修改既有的程式碼。為了確保在每一次改動之後的軟體品質,回歸測試是一個不可或缺的一環。為了讓測試人員進行回歸測試更有效率,本實驗室開發了一套錄製/播放類的測試軟體-Korat。 在一開始把Korat推廣到業界使用時,我們發現了Korat這種錄製/播放類的軟體,在進行直線式的測試案例時是可以運作良好的,但是對當時的Korat而言若是測試案例不是直線式的時候就會無法處理。把Korat應用在BIOS大廠AMI的測試案例之上時,其中一部分的測試案例需要使用到branch的功能,讓測試案例能在不同的情況之下產生不同的反應。但是在錄製時會因為待測系統只會進入其中的一條路徑,所以當時的Korat在使用錄製的方式建立非直線型的測試案例會碰到一些困難。 本論文將針對Korat這個錄製/播放類的測試工具無法錄製像是branch這一類非直線型測試案例這一問題提出解決方法,並且透過改良Korat讓Korat可以以錄製的方式建立這一類測試案例以驗證此方法的可行性。;In order to fix the software bug or add functionality into software, engineers often need to frequently modify the existing source code in the software development life cycle. In order to ensure existing features are not damaged by the changes, regression testing is an indispensable quality assurance activity in modern software engineering. In the past, our lab developed a record/replay testing tool – Korat. Korat′s major advantage is that it frees the testers from programming, testing, and debugging test code. We have been aware of that Korat is not capable of processing some test cases when we introduced Korat to the industry. Korat works well on linear test cases, but not on non-linear test cases. When applied Korat to the AMI (a well-known BIOS company) test cases, some of the test cases require the branch function to react differently under different conditions. However, the system under test only enters one of the paths when recording. As a result, Korat encounters difficulties in establishing a non-linear test case at that time. This paper proposes a solution to the non-linear branch recording problem. To proof the feasibility of this solution, I will improve Korat to make it possible to recording non-linear test cases.