WebConf Taiwan
    • Create new note
    • Create a note from template
      • Sharing URL Link copied
      • /edit
      • View mode
        • Edit mode
        • View mode
        • Book mode
        • Slide mode
        Edit mode View mode Book mode Slide mode
      • Customize slides
      • Note Permission
      • Read
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Write
        • Only me
        • Signed-in users
        • Everyone
        Only me Signed-in users Everyone
      • Engagement control Commenting, Suggest edit, Emoji Reply
    • Invite by email
      Invitee

      This note has no invitees

    • Publish Note

      Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

      Your note will be visible on your profile and discoverable by anyone.
      Your note is now live.
      This note is visible on your profile and discoverable online.
      Everyone on the web can find and read all notes of this public team.
      See published notes
      Unpublish note
      Please check the box to agree to the Community Guidelines.
      View profile
    • Commenting
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Suggest edit
      Permission
      Disabled Forbidden Owners Signed-in users Everyone
    • Enable
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
    • Emoji Reply
    • Enable
    • Versions and GitHub Sync
    • Note settings
    • Note Insights New
    • Engagement control
    • Transfer ownership
    • Delete this note
    • Save as template
    • Insert from template
    • Import from
      • Dropbox
      • Google Drive
      • Gist
      • Clipboard
    • Export to
      • Dropbox
      • Google Drive
      • Gist
    • Download
      • Markdown
      • HTML
      • Raw HTML
Menu Note settings Note Insights Versions and GitHub Sync Sharing URL Create Help
Create Create new note Create a note from template
Menu
Options
Engagement control Transfer ownership Delete this note
Import from
Dropbox Google Drive Gist Clipboard
Export to
Dropbox Google Drive Gist
Download
Markdown HTML Raw HTML
Back
Sharing URL Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Customize slides
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Engagement control Commenting, Suggest edit, Emoji Reply
  • Invite by email
    Invitee

    This note has no invitees

  • Publish Note

    Share your work with the world Congratulations! 🎉 Your note is out in the world Publish Note

    Your note will be visible on your profile and discoverable by anyone.
    Your note is now live.
    This note is visible on your profile and discoverable online.
    Everyone on the web can find and read all notes of this public team.
    See published notes
    Unpublish note
    Please check the box to agree to the Community Guidelines.
    View profile
    Engagement control
    Commenting
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    • Everyone
    Suggest edit
    Permission
    Disabled Forbidden Owners Signed-in users Everyone
    Enable
    Permission
    • Forbidden
    • Owners
    • Signed-in users
    Emoji Reply
    Enable
    Import from Dropbox Google Drive Gist Clipboard
       Owned this note    Owned this note      
    Published Linked with GitHub
    • Any changes
      Be notified of any changes
    • Mention me
      Be notified of mention me
    • Unsubscribe
    # GenAI 時代下的測試三板斧 - 柯仁傑 {%hackmd o8oUosN0QnqMSkF1_6kH7g %} ## 📚 議程介紹 {%preview https://webconf.tw/agenda/27 %} ## ▼▼▼ 開始筆記 ▼▼▼ ### 大綱 * GenAI真的懂軟體測試? * 開立測試案例的提示工程 * 利用實例化需求讓生成有共識 * 利用探索性測試+AI快速抓錯 ### GenAI真的懂軟體測試? 生成式AI 讓機器產生複雜有結構的物件。 - 文章 - 影像 - 語音 來源:李宏毅 - [【生成式 AI 導論 2024】第1講:生成式 AI 是什麼?](https://www.youtube.com/watch?v=JGtqpQXfJis) [【生成式人工智慧與機器學習導論2025】第1講:一堂課搞懂生成式人工智慧的原理](https://www.youtube.com/watch?v=TigfpYPJk1s) LLM 模型怎樣生出來? - 自督導式學習 - 督導式學習 - 增強式學習 定義非常多元 - Stress Testing the art of testing->壓力測試涉及讓程序承受重負載或壓力。在短時間內遇到的資料量峰值。 widi->通常用於了解系統容量的上限。此類測試旨在確定系統在極端負載下的 表現 - Performance testing the art of testing -> 目的是證明程式未達到其目標 wikipedia->效能測試通常是一種測試實踐,是一種集合名詞 網路上的資料 新手練習/不完整的答案/過時的作法. GenAI 時代的測試錯覺 PM : AI 能幫忙測品質 => 可能只是加速錯誤的流動. 開發人員:AI 能自動測試 =>可能只是 Happy path 或 ret true 測試人員:AI 幫自動生 test case =>可能只是更多檢視確認 測試三板斧: - 利用測試知識充實提示樣板 - 利用實例化需求加強協作與共識 - 利用探索性測試 人機協作彌補自動化的不足 ### 開立測試案例的提示工程 - 你是軟體測試專家,擅長XXX領域. - 請對功能XXX開立測試案例. - 要有正向,反向,邊界值得案例 > 這些形容詞沒用啦,效果有限,你可以繼續燒你的token但其實幫助真的不大 - 輸出格式:標題、步驟、輸入、預期結果 > 還不錯? 但要想一想, 有這些格式是可以讓輸出比較固定,對自動化有幫助 >所有AI出來的東西都要容易review,不是生出來就很雜或敘述性的格式就超級難review的。 >重點在於要容易review,例如:表格 >Given-When-Then 的格式 - 輸入部分要有具體的值, 預期結果要真的能比對出是否通過. #### 什麼是測試個案 - IEEE Std 829-1983 >用來描述測試時,所需要的*輸入*,*預期結果*,和一連串 *執行條件* 的一份文件 - 請用Equivalence Class Testing 方法開立 Non-Functional Test 易用性測試 Usability Testing 效能測試 Performance Testing Security Testing Stress Test eeee 測試方法的關係. 黑箱測試(Black-box) - Equivalence Class Testing 為例: 切出partition 來做描述。 ![IMG_2586](https://hackmd.io/_uploads/S1mQdD5fbe.jpg) ![IMG_2587](https://hackmd.io/_uploads/rkqEdDczbe.jpg) GenAI 不懂軟體測試. 只會分'有效'跟'無效' 看太多管顧公司的文章. 你自己要review , 即時如此, 還是要review e.g. 有沒有早鳥票/早鳥票賣完. ![IMG_2588](https://hackmd.io/_uploads/H1lqdPqfWe.jpg) Prompt 要靠 軟體測試知識+領域知識 才能下的好. for testing : 問廣問深, 不同角度的風險(測試方法 = 從不同角度看同一個風險) ### 利用實例化需求讓生成有共識 吳恩達 需求分析 架構設計 細部設計 開發 測試 結案 但架構設計到開發中間的速度變快了 重點: 我們接下來應該做什麼 ![IMG_2590](https://hackmd.io/_uploads/SJ8_Kvqf-l.jpg) 2 PM + 1 Dev 將來需要: - 會寫程式碼的產品經理 - 什麼東西會是不變的? SDD - Spec Kit Constitution -> Specify -> plan -> tasks -> implement <div style="color:red; font-size:42px;"> 但是以前你說看不懂 PM 寫的文件 !!??</div> 還少這一味: BDD / SBE (Spec by Example) --- #### Specify.md 可能的內容 + 範例 ##### Problem >使用者想要以最便宜的票價搭乘高鐵,並希望在訂票時能知>道該車次是否有早鳥折扣,以及是否還有折扣名額。 ##### Rules > 早鳥優惠僅適用於「標準車廂對號座單程全票」。 > 折扣等級有三種,優先順序為:65 折 -> 8 折 -> 9 折。售完 65 折後才賣 8 折,8 折售完後才賣 9 折,9 折售完即恢復原價。 > 折扣票數量有限,若單筆訂購多張票,必須確認「剩餘早鳥優惠座位數 ≥ 要求張數」,才能套用優惠票價,否則可能部分或全部退回原價。 > 最晚折扣票販售至「乘車日 (含) 前 5 日」為止。 ##### Examples > 使用者查詢 2025-09-01 的某列車,並發現剩餘 65 折票 -> 系統顯示該列車票價為 65 折 -> 使用者訂票成功。 > 使用者查詢 2025-09-01 的某列車,但 65 折票已售完 -> 系統顯示 8 折票剩餘 -> 若使用者訂票 -> 系統套用 8 折票價。 > 使用者查詢某列車,但早鳥折扣票數已售完 (65 / 8 / 9 均售完) -> 系統標示為「原價票」並售出原價票。 > 使用者欲訂購兩張折扣票,但系統剩餘折扣票只剩一張 -> 系統應拒絕折扣票 (或提示折扣票不足) -> 或者退回整筆訂單至原價 (依團隊需求決定)。 > 使用者查詢距離乘車日 4 天內的車票 -> 系統不得提供任何早鳥折扣、僅顯示原價票。 --- 99%的人都把心力集中在自動化. (如何對齊開發與PM的需求??) 這樣充其量只是一個新的測試自動化啊! 不是在釐清需求 你終究只是寫給自己爽而已啊 你到底寫東西是要符合需求,還是只是寫給炫技,用一些根本看不懂但很潮的新技術? 釐清需求, 是要列出你不清楚的才要列. 實例化需求, 是要寫功能性的內容, 而不是UI/流程上的操作. 利用需求制定不變的基石, 這個是需求要所有人都有共識. The State of Software Quality Report 2025 BDD/TDD 51% ### 利用探索性測試+AI快速抓錯 Henrik: 1天的迭代. 2 week 迭代 -> 1天迭代. 不管週期多長, 就是沒時間測試. > 不是沒時間, 是沒習慣. AI會補你沒說的(腦補) e.g. 日期合不合理這件事. AI 會想跨日怎麼算? 可接受的format = ? 還是要review AI也會跑測試 , 每次都說通過, 到底是真的還是假的. 測試不只是檢查. Checking / Exploring ![IMG_2600](https://hackmd.io/_uploads/BJc92wqMbx.jpg) 40%~60% 的bug 不是從test case找到的. > 代表那個 QA 會不斷質疑. AI 會做QA這種質疑嗎? NO --- 聊天室 好難記. >感謝筆記之神 SDD 會不會很燒token ? > 燒啊 總比燒腦好XD 修bug 要重寫spec 再跑一次. 在我的電腦上沒問題 現在就是叫AI直接產範例 會好理解很多 AI搞不懂你的意思 大概人也搞不懂XD 被人說看不懂會生氣 被AI說看不懂就不會XD

    Import from clipboard

    Paste your markdown or webpage here...

    Advanced permission required

    Your current role can only read. Ask the system administrator to acquire write and comment permission.

    This team is disabled

    Sorry, this team is disabled. You can't edit this note.

    This note is locked

    Sorry, only owner can edit this note.

    Reach the limit

    Sorry, you've reached the max length this note can be.
    Please reduce the content or divide it to more notes, thank you!

    Import from Gist

    Import from Snippet

    or

    Export to Snippet

    Are you sure?

    Do you really want to delete this note?
    All users will lose their connection.

    Create a note from template

    Create a note from template

    Oops...
    This template has been removed or transferred.
    Upgrade
    All
    • All
    • Team
    No template.

    Create a template

    Upgrade

    Delete template

    Do you really want to delete this template?
    Turn this template into a regular note and keep its content, versions, and comments.

    This page need refresh

    You have an incompatible client version.
    Refresh to update.
    New version available!
    See releases notes here
    Refresh to enjoy new features.
    Your user state has changed.
    Refresh to load new user state.

    Sign in

    Forgot password

    or

    By clicking below, you agree to our terms of service.

    Sign in via Facebook Sign in via Twitter Sign in via GitHub Sign in via Dropbox Sign in with Wallet
    Wallet ( )
    Connect another wallet

    New to HackMD? Sign up

    Help

    • English
    • 中文
    • Français
    • Deutsch
    • 日本語
    • Español
    • Català
    • Ελληνικά
    • Português
    • italiano
    • Türkçe
    • Русский
    • Nederlands
    • hrvatski jezik
    • język polski
    • Українська
    • हिन्दी
    • svenska
    • Esperanto
    • dansk

    Documents

    Help & Tutorial

    How to use Book mode

    Slide Example

    API Docs

    Edit in VSCode

    Install browser extension

    Contacts

    Feedback

    Discord

    Send us email

    Resources

    Releases

    Pricing

    Blog

    Policy

    Terms

    Privacy

    Cheatsheet

    Syntax Example Reference
    # Header Header 基本排版
    - Unordered List
    • Unordered List
    1. Ordered List
    1. Ordered List
    - [ ] Todo List
    • Todo List
    > Blockquote
    Blockquote
    **Bold font** Bold font
    *Italics font* Italics font
    ~~Strikethrough~~ Strikethrough
    19^th^ 19th
    H~2~O H2O
    ++Inserted text++ Inserted text
    ==Marked text== Marked text
    [link text](https:// "title") Link
    ![image alt](https:// "title") Image
    `Code` Code 在筆記中貼入程式碼
    ```javascript
    var i = 0;
    ```
    var i = 0;
    :smile: :smile: Emoji list
    {%youtube youtube_id %} Externals
    $L^aT_eX$ LaTeX
    :::info
    This is a alert area.
    :::

    This is a alert area.

    Versions and GitHub Sync
    Get Full History Access

    • Edit version name
    • Delete

    revision author avatar     named on  

    More Less

    Note content is identical to the latest version.
    Compare
      Choose a version
      No search result
      Version not found
    Sign in to link this note to GitHub
    Learn more
    This note is not linked with GitHub
     

    Feedback

    Submission failed, please try again

    Thanks for your support.

    On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

    Please give us some advice and help us improve HackMD.

     

    Thanks for your feedback

    Remove version name

    Do you want to remove this version name and description?

    Transfer ownership

    Transfer to
      Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

        Link with GitHub

        Please authorize HackMD on GitHub
        • Please sign in to GitHub and install the HackMD app on your GitHub repo.
        • HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.
        Learn more  Sign in to GitHub

        Push the note to GitHub Push to GitHub Pull a file from GitHub

          Authorize again
         

        Choose which file to push to

        Select repo
        Refresh Authorize more repos
        Select branch
        Select file
        Select branch
        Choose version(s) to push
        • Save a new version and push
        • Choose from existing versions
        Include title and tags
        Available push count

        Pull from GitHub

         
        File from GitHub
        File from HackMD

        GitHub Link Settings

        File linked

        Linked by
        File path
        Last synced branch
        Available push count

        Danger Zone

        Unlink
        You will no longer receive notification when GitHub file changes after unlink.

        Syncing

        Push failed

        Push successfully