lazyscout 0.1.0 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -1,118 +1,88 @@
1
1
  # LazyScout
2
2
 
3
- เครื่องมือช่วย Software Tester วิเคราะห์เว็บไซต์แล้วสร้าง **Draft Test Case** และ **Test Data**
4
- อัตโนมัติ พร้อม export เป็น CSV เปิดใน Excel / Google Sheets ได้ทันที
3
+ LazyScout is a local-first QA assistant that explores web applications, drafts test cases, and generates automation code for Playwright and Cypress.
5
4
 
6
- **ทำงานในเครื่องคุณเอง** — ไม่ต้องสมัครสมาชิก ไม่ต้องล็อกอิน ไม่ส่งข้อมูลออกไปไหน
7
- จึงสแกน `http://localhost` และระบบภายในองค์กรได้
5
+ > Stop rewriting QA work.
8
6
 
9
- ```bash
10
- npx lazyscout
11
- ```
12
-
13
- ---
7
+ ## Quick Start
14
8
 
15
- ## ใช้งาน
16
-
17
- ### เปิดหน้าเว็บ (แนะนำ)
9
+ Requires Node.js 20 or newer and Chrome, Edge or Playwright Chromium.
18
10
 
19
11
  ```bash
20
- npx lazyscout
12
+ npx lazyscout@latest
21
13
  ```
22
14
 
23
- เปิดหน้าจอที่ `http://localhost:4321` ให้อัตโนมัติ → ใส่ URL → กด **Analyze Website**
24
- → แก้ไข test case ในตาราง → **Export CSV**
15
+ LazyScout starts its UI on `http://localhost:4321` and opens it automatically.
25
16
 
26
- ### โหมดบรรทัดคำสั่ง (เหมาะกับ CI)
17
+ If a supported browser is not installed:
27
18
 
28
19
  ```bash
29
- npx lazyscout scan http://localhost:5173
30
- npx lazyscout scan https://example.com --max-pages 10 --csv report.csv --json raw.json
31
- ```
32
-
33
- | ตัวเลือก | ความหมาย |
34
- | --- | --- |
35
- | `--csv <ไฟล์>` | บันทึก test case + test data เป็น CSV (ค่าเริ่มต้น `lazyscout-testcases.csv`) |
36
- | `--json <ไฟล์>` | บันทึกผลดิบทั้งหมด (page model + test case + test data) |
37
- | `--max-pages <n>` | จำนวนหน้าสูงสุด (ค่าเริ่มต้น 20) |
38
- | `--max-depth <n>` | ความลึกสูงสุด (ค่าเริ่มต้น 3) |
39
- | `--port <n>` | พอร์ตของหน้าเว็บ (ค่าเริ่มต้น 4321) |
40
- | `--no-open` | ไม่ต้องเปิดเบราว์เซอร์ให้อัตโนมัติ |
41
-
42
- ---
43
-
44
- ## ได้อะไรออกมา
45
-
46
- **Test Cases** — สร้างจากสิ่งที่ตรวจพบจริงบนหน้าเว็บ
47
-
48
- ```
49
- TC-LOGIN-001 positive/ready Login page displays required controls
50
- TC-LOGIN-002 validation/needs-review Email is required
51
- TC-LOGIN-003 validation/needs-review Password is required
52
- TC-LOGIN-004 positive/needs-data Submit Login form with valid data
53
- TC-LOGIN-005 positive/ready Navigate to Register
54
- ```
55
-
56
- **Test Data** — ค่าที่ควรผ่าน/ควรถูกปฏิเสธของแต่ละช่องกรอก
57
-
58
- ```
59
- TD-LOGIN-001 Email email required qa.tester@example.com invalid-email
60
- TD-LOGIN-002 Password password required Passw0rd!23 123
20
+ npx playwright install chromium
61
21
  ```
62
22
 
63
- **CSV** — ไฟล์เดียวมีทั้งสองส่วน มี UTF-8 BOM ภาษาไทยไม่เพี้ยนใน Excel
23
+ ## CLI scan
64
24
 
25
+ ```bash
26
+ npx lazyscout@latest scan http://localhost:5173
27
+ npx lazyscout@latest scan https://example.com --max-pages 10 --csv report.csv --json raw.json
65
28
  ```
66
- TC_ID, Module, Title, Preconditions, Test_Steps, Expected_Result, Type, Priority, Automation_Status, Source_URL
67
- ```
68
-
69
- ---
70
29
 
71
- ## ความปลอดภัย
30
+ | Option | Purpose |
31
+ | ----------------- | ------------------------------------------------------ |
32
+ | `--csv <file>` | CSV output path; defaults to `lazyscout-testcases.csv` |
33
+ | `--json <file>` | Optional raw exploration output |
34
+ | `--max-pages <n>` | Maximum pages; defaults to 20 |
35
+ | `--max-depth <n>` | Maximum same-origin link depth; defaults to 3 |
36
+ | `--port <n>` | Local UI port; defaults to 4321 |
37
+ | `--no-open` | Start without opening the browser |
72
38
 
73
- เครื่องมือนี้ออกแบบให้ยิงใส่ระบบที่กำลังพัฒนาได้อย่างปลอดภัย
39
+ The current CLI command is `scan`; there is no `analyze` command.
74
40
 
75
- - **ไม่คลิกปุ่มและไม่ submit form** — เดินทางด้วยลิงก์ (`href`) เท่านั้น จึงไม่เปลี่ยนแปลงข้อมูลของระบบ
76
- - **ตรวจพบ action อันตราย แต่ไม่แตะ** — Delete, Payment, Logout ฯลฯ จะถูกบันทึกเป็น test case แบบ `manual` ให้ทดสอบด้วยมือ
77
- - **สำรวจเฉพาะ origin เดียวกัน** ไม่ออกไปโดเมนอื่น
78
- - จำกัด 20 หน้า / ลึก 3 ชั้น / มี timeout และกันการวนลูป
41
+ ## Available Features
79
42
 
80
- ## ไม่เดา expected result
43
+ - Playwright website and form exploration
44
+ - UI control, visible dialog and interaction discovery
45
+ - English/Thai Draft Test Cases and Test Data
46
+ - Test Case review, folders, tags and requirement links
47
+ - CSV/XLSX/JSON import and CSV export
48
+ - Screenshot OCR-assisted import
49
+ - Playwright and Cypress code generation
50
+ - Local Playwright execution with restricted statements, logs and screenshots
51
+ - Safe GET/HEAD/OPTIONS API checks
52
+ - Bug Reports with ZIP evidence export
53
+ - HTML/PDF Test Summary
54
+ - Confirmed local GET load test
81
55
 
82
- ถ้าระบบไม่มีหลักฐานว่า behavior จริงคืออะไร จะไม่แต่งขึ้นมาเอง แต่จะเขียนว่า
56
+ Cypress is code generation only; the built-in local runner uses Playwright.
83
57
 
84
- > Verify that the result is displayed according to application requirements (needs review by tester).
58
+ ## Local-first Data
85
59
 
86
- แล้วตั้งสถานะเป็น `needs-review` — **ผลลัพธ์คือ Draft ที่ Tester ต้องตรวจ ไม่ใช่ test case ที่ถูกต้อง 100%**
60
+ Browser automation runs on your machine. Projects, Test Cases, results, Bug Reports and screenshots are stored in the local browser. Credentials entered in Project Settings stay in memory for the current tab and are cleared on refresh. Environment variables are supported for local runner credentials.
87
61
 
88
- ---
62
+ Version Center contacts npm Registry to check available releases. LazyScout has no hosted account or Project database in the current version.
89
63
 
90
- ## ความต้องการของระบบ
64
+ ## Safety
91
65
 
92
- - **Node.js 20 ขึ้นไป**
93
- - **Google Chrome หรือ Microsoft Edge** อย่างใดอย่างหนึ่ง (เครื่องส่วนใหญ่มีอยู่แล้ว)
66
+ Scouting is same-origin, follows links and blocks destructive labels. Edited automation is interpreted through a Playwright statement whitelist; it is not executed as arbitrary JavaScript or shell source.
94
67
 
95
- แพ็กเกจนี้ใช้ `playwright-core` จึงไม่ดาวน์โหลดเบราว์เซอร์ 150MB ตอนติดตั้ง แต่จะหาเบราว์เซอร์
96
- ในเครื่องคุณตามลำดับ: Chromium ของ Playwright → Chrome → Edge
68
+ > Never commit real test credentials, production data, browser authentication state, Playwright traces, screenshots, HAR files, or API dumps containing sensitive information.
97
69
 
98
- ถ้าไม่มีสักตัว ติดตั้งด้วย:
70
+ > Use synthetic test data whenever possible.
99
71
 
100
- ```bash
101
- npx playwright install chromium
102
- ```
72
+ > Review generated test cases and automation code before executing them against critical environments.
103
73
 
104
- > **Windows:** ถ้าใช้ `cmd.exe` รุ่นเก่าแล้วภาษาไทยแสดงไม่ถูก ให้พิมพ์ `chcp 65001` ก่อน
105
- > หรือใช้ Windows Terminal / PowerShell 7 ซึ่งรองรับ UTF-8 อยู่แล้ว
74
+ Generated Test Cases are drafts, not a replacement for QA judgment. Use DEV, UAT, sandbox or another authorized test environment before production.
106
75
 
107
- ---
76
+ ## Documentation
108
77
 
109
- ## แผนในอนาคต
78
+ - [GitHub repository](https://github.com/nowaa2/lazyscout)
79
+ - [Security policy](https://github.com/nowaa2/lazyscout/blob/main/SECURITY.md)
80
+ - [Thai README](https://github.com/nowaa2/lazyscout/blob/main/README_TH.md)
81
+ - [Issue tracker](https://github.com/nowaa2/lazyscout/issues)
110
82
 
111
- โครงสร้างภายในแยก Test Case Model ออกจาก Playwright โดยสิ้นเชิง จึงเพิ่มสิ่งเหล่านี้ได้
112
- โดยไม่ต้องแก้ตัวสำรวจเว็บ:
83
+ ## Author
113
84
 
114
- - `TestCase[]` → Playwright `.spec.ts`
115
- - `TestCase[]` → Cypress `.cy.ts`
85
+ Created by **nowzaa** — [GitHub profile](https://github.com/nowaa2)
116
86
 
117
87
  ## License
118
88