File tree Expand file tree Collapse file tree 1 file changed +4
-12
lines changed
Expand file tree Collapse file tree 1 file changed +4
-12
lines changed Original file line number Diff line number Diff line change @@ -22,30 +22,22 @@ jobs:
2222
2323 - name : Start the server
2424 run : |
25- python server.py -s & # Start the server in the background
25+ python server.py -s &
2626 echo "Server started"
2727
2828 - name : Wait for server to be ready
2929 run : sleep 5
3030
31- - name : Send GET request and check response
32- id : check_response
31+ - name : Send GET request
3332 run : |
3433 response=$(curl -s http://localhost:5000)
3534 echo "Response: $response"
36- if [ "$response" == "Hello there!" ]; then
37- echo "The value received is correct"
38- echo "::set-output name=status::success"
39- else
40- echo "Received value is incorrect"
41- echo "::set-output name=status::failure"
42- exit 1
43- fi
4435
4536 - name : Output result
4637 run : |
47- if [ "${{ steps.check_response.outputs.status }} " == "success " ]; then
38+ if [ "$response " == "Hello there! " ]; then
4839 echo "The value received is correct"
4940 else
5041 echo "Received value is incorrect"
42+ exit 1
5143 fi
You can’t perform that action at this time.
0 commit comments