Skip to content

Commit

Permalink
docs(software-testing): add paul jorgensen formula for ch5
Browse files Browse the repository at this point in the history
  • Loading branch information
zyf722 committed Apr 20, 2024
1 parent 2c4a09e commit 4589bb4
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions docs/software-testing/ch5-testing-with-blindfold.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,17 @@
#### 测试边界
仅仅测试边界点是不够的,最好是还能测试边界的两侧:一边测试刚好超过边界的**无效数据**,另一边测试刚好在边界内的**有效数据**

#### ⭐ Paul C. Jorgensen 公式
设 $n$ 为存在边界值的参数个数,$m$ 为边界值条件数,则有

- **$4n+1$ 公式:基本边界测试**
- 每个参数取 $min$,$min+1$, $max‐1$, $max$ 各一次,
同时其他参数取典型值 $nom$;最后全部参数取典型值 $nom$,额外记一次。
- **$6n+1$ 公式:健壮性边界测试**
- 在基本边界测试基础上,为每个参数增加 $min‐1$ 和 $max+1$ 的测试。
- **$3m$ 公式:边界条件测试**
- 每个条件值 $c_i$ 取 $c_i-1$, $c_i$, $c_i+1$ 各一次。

### 选择测试用例:次边界条件
上述的普通边界条件是很容易在产品说明书或软件的过程中找到的,然而有些边界条件却隐藏在软件内部,最终用户很难发现,软件测试员却必须对其进行测试。这就是**次边界条件**(Sub-boundary condition)或者**内部边界条件**(Internal boundary condition)。

Expand Down

0 comments on commit 4589bb4

Please sign in to comment.