|
7 | 7 | # Workflow input parameters: |
8 | 8 | # * test_type: The testing type. In generally, it only has 2 options: 'unit-test' and 'integration-test'. |
9 | 9 | # * all_test_items_paths: The target paths of test items under test. |
| 10 | +# * setup_http_server: If it's true, it would set up and run HTTP server for testing. |
| 11 | +# * auto_install_http_server_dependencies: If it's true, it would auto-install the Python dependencies it needs of setup HTTP server. The Python dependencies are 'flask' and 'gunicorn'. |
| 12 | +# * http_server_host: The host IPv4 address of HTTP server. |
| 13 | +# * http_server_port: The port number of HTTP server. |
| 14 | +# * http_server_app_module: The module path of HTTP server. |
| 15 | +# * http_server_enter_point: The object about the web application. |
10 | 16 | # |
11 | 17 | # Workflow running output: |
12 | 18 | # No, but it would save the testing coverage reports to provide after-process to organize and record. |
|
27 | 33 | required: true |
28 | 34 | type: string |
29 | 35 | setup_http_server: |
30 | | - description: "If it's true, it would setup and run a sample HTTP server." |
| 36 | + description: "If it's true, it would set up and run HTTP server for testing." |
| 37 | + type: boolean |
| 38 | + required: false |
| 39 | + default: false |
| 40 | + auto_install_http_server_dependencies: |
| 41 | + description: "If it's true, it would auto-install the Python dependencies it needs of setup HTTP server. The Python dependencies are 'flask' and 'gunicorn'." |
31 | 42 | type: boolean |
32 | 43 | required: false |
33 | 44 | default: false |
34 | 45 | http_server_host: |
35 | | - description: "If it's true, it would setup and run a sample HTTP server." |
| 46 | + description: "The host IPv4 address of HTTP server." |
36 | 47 | type: string |
37 | 48 | required: false |
38 | 49 | default: 0.0.0.0 |
39 | 50 | http_server_port: |
40 | | - description: "If it's true, it would setup and run a sample HTTP server." |
| 51 | + description: "The port number of HTTP server." |
41 | 52 | type: string |
42 | 53 | required: false |
43 | 54 | default: 12345 |
44 | 55 | http_server_app_module: |
45 | | - description: "If it's true, it would setup and run a sample HTTP server." |
| 56 | + description: "The module path of HTTP server." |
46 | 57 | type: string |
47 | 58 | required: false |
48 | 59 | default: app |
49 | 60 | http_server_enter_point: |
50 | | - description: "If it's true, it would setup and run a sample HTTP server." |
| 61 | + description: "The object about the web application." |
51 | 62 | type: string |
52 | 63 | required: false |
53 | 64 | default: app |
54 | | -# dockerfile: |
55 | | -# description: "The file path of Dockerfile." |
56 | | -# required: false |
57 | | -# type: string |
58 | | -# docker_container_name: |
59 | | -# description: "The name of docker container." |
60 | | -# required: false |
61 | | -# default: gh_ci_container |
62 | | -# type: string |
63 | | -# docker_cmd_options: |
64 | | -# description: "The command options of 'docker run'." |
65 | | -# required: false |
66 | | -# type: string |
67 | | -# docker_image_tag: |
68 | | -# description: "The tag of image which be built by Dockerfile." |
69 | | -# required: false |
70 | | -# default: gh_ci_container:v0 |
71 | | -# type: string |
72 | | -# docker_context_path: |
73 | | -# description: "The path where is the context path of Dockerfile." |
74 | | -# required: false |
75 | | -# default: ./ |
76 | | -# type: string |
77 | 65 |
|
78 | 66 |
|
79 | 67 | jobs: |
@@ -112,29 +100,11 @@ jobs: |
112 | 100 | steps: |
113 | 101 | - uses: actions/checkout@v2 |
114 | 102 |
|
115 | | -# - name: Build Docker image via Dockerfile |
116 | | -# if: ${{ inputs.dockerfile }} |
117 | | -# run: | |
118 | | -# docker build -t ${{ inputs.docker_image_tag }} ${{ inputs.docker_context_path }} -f ${{ inputs.dockerfile }} |
119 | | -# docker images |
120 | | -# |
121 | | -# - name: Run docker container with docker image |
122 | | -# if: ${{ inputs.dockerfile }} |
123 | | -# run: | |
124 | | -# docker run --name ${{ inputs.docker_container_name }} ${{ inputs.docker_cmd_options }} -d ${{ inputs.docker_image_tag }} |
125 | | -# docker ps -a |
126 | | - |
127 | 103 | - name: Install Python ${{ matrix.python-version }} |
128 | 104 | uses: actions/setup-python@v2 |
129 | 105 | with: |
130 | 106 | python-version: ${{ matrix.python-version }} |
131 | 107 |
|
132 | | -# - name: Install dependencies by cloning from GitHub MultiRunnable |
133 | | -# run: | |
134 | | -# git clone https://github.com/Chisanan232/multirunnable.git -b master ./multirunnable |
135 | | -# sudo python ./multirunnable/setup.py install |
136 | | -# pip install -r ./multirunnable/dev-requirements.txt |
137 | | - |
138 | 108 | - name: Install Python dependencies |
139 | 109 | run: | |
140 | 110 | python -m pip install --upgrade pip |
|
0 commit comments