Automation Testing

 


a. Right Mindset

    a. Automation complement manual testing

    b. Automation harus ROI Positive (Benefit > Cost)

    c. Automation butuh maintenance (tidak sekali buat selamanya jalan)


b. Pendekatan

    1. Manual testing : untuk fitur baru (Exploratory testing)

    2. Automation testing : untuk fitur standar yang selalu sama (Regression testing)


c. Karakteristik automation

    1. Simple alurnya

    2. Fiturnya stabil (tidak sering berubah)

    3. Mampu dijalankan berkali-kali (setiap release / sprint)

    4. Langkah sama bisa di ulang-ulang dan bisa diprediksi hasilnya.


d. Perhitungan untuk menentukan layak dan tidak layak di automation

Formula ROI Automation

ROI = ((Benefit - Cost) / Cost ) * 100%


Benefit

    1. Time saved per execution * Number of execution

    2. Bug found earlier

    3. Reduced human error


Cost

    1. Time to write automation script

    2. Maintenance time

    3. Tool/infrastruktur cost

    4. Training Cost


Layak di automation = High ROI

ciri-cirinya waktu eksekusinya cepat


tidak layak di automation = Low ROI

Memakan waktu lama untuk eksekusi


TDD -> Developer (Pendekatan by Code)

BDD -> QA (Pendekatan by behaviour)


e. Kapan menggunakan BDD

    1. Ketika Tim Cross Functional (BA,QA, Dev, dsb) saling berkolaborasi

    2. Requirement Complex

    3. End to End Testing (user behaviour)

    4. Butuh dokumentasi


Kapan tidak pakai BDD

    1. Tim kecil (hanya Dev)

    2. Fiturnya  Simple

    3. Unit Testing (TDD)

    4. Timnya tidak familiar Gherkin


f.  Sprint work flow - 2 minggu

    1. Sprint Planning (hari : 1-2 )

        a. Review user story dengan team

        b. Define acceptance kriteria

        c. Identifikasi automation yang akan diuji

        d. Estimasi testing effort


    2. Development + testing (hari : 3-8)

        a. Menulis test case (manual + automation)

        b. Mempersiapkan test data

        c. Mensetup test environment

        d. Berkolaborasi dengan developer untuk melakukan paralel test


    3. Testing (Integration + regression) (Hari: 9-11)

        a. Exploratory Testing

        b. Menjalankan automation (Regression)

        c.  Melaporkan bug

        d. Melakukan pengujian ulang bug yang sudah diperbaiki


    4. UAT Preparation (Hari : 12)

        a. Mempersiapkan uat environment

        b. Mempersiapkan uat scenario

        c. Melatih tim bisnis


    5. Sprint Review (hari : 13)

        a. Demo test result

        b. Showcase automation script


    6. Sprint restrospective (automation maintenance) (hari: 14)

        a. Update Automation Suite (Menambah test case baru / delete)

        b. refactor flaky test

        c. update documentation

        d. plan automation for next sprint


g. Automation Maintenance (Setiap Jumat)

    1. Review flaky test

        a. identify test dengan > 10% failure rate

        b. fix or disable flaky test


    2. Update test data

        a. Refresh test user account

        b. Update product test data

        c. Reset database to ckean state


    3.  Update Locators (If UI Change)

        a. Check if button ID Changed

        b. Update CSS Selectors

        c. Update Xpath


    4. Performance Check

        a. Review test execution time

        b. Optimize Slow test

        c. Consider Parallel execution


    5. Coverage Review

        a. Cek apakah fitur baru sudah tercover

        b. Remove test for deprecated features


    6. Documentation Update

        a. Update README

        b. Update test case mapping

h. Checklist Sebelum Demo

        1. Code Readiness

                a. Push code to GitHub (Public)

                b. Add README with setup instruction

                c. Add Comments in code

                d. Ensure code run on fresh environment


        2. Demo Environment

                a. Test on clean laptop (not just your machine)

                b. record video demo (backup plan if demo fail)

                c. prepare screenshot


        3. Test data

                a. minta dan siapkan data dari perusahaan

                b. avoid company confidential data

    

        4. Documentation

                a. Create test case document (Link automation to manual test case)

                b. Create test report

                c. Create architecture diagram

    

        5.  Talking Point

            a. Write challenge you faced 

            b. Write Learning

            c. Write metric (Coverage %, Execution time, and Bug found)


i. Cara Demo

        1. Sebutkan % coverage dari total test case

        2. Sebutkan :

                a. Jenis test yang dikerjakan

                b. waktu eksekusi

       3. Jika ada, sebutkan :

                a. Sisa % test yang belum di eksekusi

                b. Jenis test

                c. Alasan kenapa belum di eksekusi

        4.Tunjukkan & jelaskan kodingmu ( jika ditanya)

        5. Demokan automationmu ( jika ditanya)

        6. Jelaskan tantangan dan masalah yang dihadapi serta berikan solusinya

            a.  flaky test

            b. test maintenance

            c. test data management 

            dll.

        7. Jelaskan hal yang dipelajari

        8. Jika di tanya, beritahu hal apa yang kamu improve :

                a. CI/CID

                b. Parallel eksekusi

                c. Visual regresi

                d. API Contract Testing

                e. Performance Integration

No comments:

Post a Comment

Pages