[💡 Feature]: Allow presets and to customize the test run command

Đang mở
#53 1 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
25/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
typescript, vscode

Hướng nghiên cứu

The issue asks for a setting, such as customRunCommand, that replaces the extension's built-in test run command with a user-defined one. Its placeholders are configFile, specFile and specLineNumber. Start by finding where the extension builds the single-spec run command and how it reads its settings. Maintainers have not agreed on the design, and the issue has had no comments in 525 days, so confirm the approach with them before writing code. Done means a configured command runs with the placeholders substituted.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

Idea 💡 Needs Triaging ⏳
Is your feature request related to a problem?

There are several use cases for having a one-click run with a custom commands.

Examples:
User uses want to debug a single test, therefore for a specific test I want to run with CLI flag --maxInstances 1 and my own custom CLI argument, I might want to run an npm script and not simply invoke the test-runner with the config.

Therefore, we could customize the command, making use of variables.

Describe the solution you'd like.

Have an option somewhere (VS Code extension option maybe)

customRunCommand: "npx wdio ${configFile} --spec "${specFile}:${specLineNumber}" --myCustomArg; echo "Done!"; curl -PUT example.com/done --data "{ done: true }"
or
customRunCommand: "npm run myscript"

When users chooses to run a specific test, the custom command runs, replacing the variables configFile, specFile and specLineNumber among others.

customRunCommand: "npx wdio cloud.wdio.conf.ts --spec "project/tests/myspec.spec.ts:123" --maxInstances 1 --myCustomArg; echo "Done!"; curl -PUT example.com/done --data "{ done: true }"

Describe alternatives you've considered.

No response

Additional context

No response

Code of Conduct
  • I agree to follow this project's Code of Conduct
Ngôn ngữ chính
TypeScript
Star
8
Fork
5
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của webdriverio/vscode-webdriverio

Tất cả issue của webdriverio/vscode-webdriverio

Issue tương tự

Thêm issue về TypeScript

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.