Skip to content

Commit 12cde43

Browse files
authored
Merge pull request #167 from Integration-Automation/dev
Dev
2 parents 35b127c + 044ffac commit 12cde43

60 files changed

Lines changed: 1438 additions & 838 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: AutoControl_Dev_Python3.10
1+
name: AutoControl Dev CI
22

33
on:
44
push:
@@ -12,84 +12,102 @@ permissions:
1212
contents: read
1313

1414
jobs:
15-
build_dev_version:
15+
test:
1616
runs-on: windows-2022
17+
strategy:
18+
fail-fast: false
19+
matrix:
20+
python-version: [ "3.10", "3.11", "3.12" ]
1721

1822
steps:
19-
- uses: actions/checkout@v3
20-
- name: Set up Python 3.10
21-
uses: actions/setup-python@v3
23+
- uses: actions/checkout@v4
24+
- name: Set up Python ${{ matrix.python-version }}
25+
uses: actions/setup-python@v5
2226
with:
23-
python-version: "3.10"
27+
python-version: ${{ matrix.python-version }}
28+
2429
- name: Install dependencies
2530
run: |
2631
python -m pip install --upgrade pip wheel
2732
pip install -r dev_requirements.txt
33+
pip install -e .
2834
29-
- name: Test Screen Module
35+
# Screen tests
36+
- name: Test Screen Size
3037
run: python ./test/unit_test/screen/screen_test.py
3138
- name: Test Screenshot
3239
run: python ./test/unit_test/screen/screenshot_test.py
3340
- name: Test Screen Get Pixel
3441
run: python ./test/unit_test/screen/get_pixel_test.py
35-
- name: Save Screenshot Image
42+
- name: Upload Screenshot Artifact
3643
uses: actions/upload-artifact@v4
44+
if: always()
3745
with:
38-
name: screenshot_png
46+
name: screenshot_png_${{ matrix.python-version }}
3947
path: test.png
48+
if-no-files-found: ignore
4049

41-
- name: Test Keyboard type Function
50+
# Keyboard tests
51+
- name: Test Keyboard Type
4252
run: python ./test/unit_test/keyboard/keyboard_type_test.py
43-
- name: Test Keyboard write Function
44-
run: |
45-
python ./test/unit_test/keyboard/keyboard_write_test.py
46-
- name: Test Keyboard is_press Function
53+
- name: Test Keyboard Write
54+
run: python ./test/unit_test/keyboard/keyboard_write_test.py
55+
- name: Test Keyboard Is Press
4756
run: python ./test/unit_test/keyboard/keyboard_is_press_test.py
48-
- name: Test Keyboard hotkey Function
57+
- name: Test Keyboard Hotkey
4958
run: python ./test/unit_test/keyboard/hotkey_test.py
59+
60+
# Mouse tests
5061
- name: Test Mouse Module
51-
run: |
52-
python ./test/unit_test/mouse/mouse_test.py
53-
exit 0
54-
- name: Test Scroll Module
55-
run: python ./test/unit_test/exception/auto_control_exception_test.py
62+
run: python ./test/unit_test/mouse/mouse_test.py
63+
continue-on-error: true
64+
65+
# Exception tests
5666
- name: Test Exceptions
5767
run: python ./test/unit_test/exception/auto_control_exception_test.py
5868

69+
# Critical exit tests
5970
- name: Test Critical Exit
60-
run: |
61-
python ./test/unit_test/critical_exit/critical_exit_test.py
62-
exit 0
71+
run: python ./test/unit_test/critical_exit/critical_exit_test.py
72+
continue-on-error: true
6373
- name: Test Real Critical Situation
64-
run: |
65-
python ./test/unit_test/critical_exit/real_critical_test.py
66-
exit 0
74+
run: python ./test/unit_test/critical_exit/real_critical_test.py
75+
continue-on-error: true
6776

77+
# Record tests
6878
- name: Test Record Module
6979
run: python ./test/unit_test/record/record_test.py
7080
- name: Test Total Record
7181
run: python ./test/unit_test/total_record/total_record_test.py
7282

83+
# Executor tests
7384
- name: Test Execute Action
7485
run: python ./test/unit_test/execute_action/execute_action_test.py
7586

76-
- name: Test Json Module
87+
# JSON tests
88+
- name: Test JSON Module
7789
run: python ./test/unit_test/json/json_test.py
78-
- name: Test Generate Json Report
90+
91+
# Report generation tests
92+
- name: Test Generate JSON Report
7993
run: python ./test/unit_test/generate_report/json_report.py
8094
- name: Test Generate HTML Report
8195
run: python ./test/unit_test/generate_report/html_report_test.py
8296

97+
# Argparse test
8398
- name: Test Argparse
8499
run: python ./test/unit_test/argparse/argparse_test.py
85100

101+
# Callback test
86102
- name: Test Callback Module
87103
run: python ./test/unit_test/callback/callback_test.py
88104

89-
- name: Test Create Project Function
105+
# Project creation test
106+
- name: Test Create Project
90107
run: python ./test/unit_test/create_project_file/create_project_test.py
91108

109+
# Info tests
92110
- name: Test Get Mouse Info
93111
run: python ./test/unit_test/get_info/mouse_info.py
94112
- name: Test Get Keyboard Info
95-
run: python ./test/unit_test/get_info/keyboard_info.py
113+
run: python ./test/unit_test/get_info/keyboard_info.py

.github/workflows/dev_python3_11.yml

Lines changed: 0 additions & 95 deletions
This file was deleted.

.github/workflows/dev_python3_12.yml

Lines changed: 0 additions & 95 deletions
This file was deleted.

0 commit comments

Comments
 (0)