Skip to content

Commit 455623e

Browse files
authored
Merge pull request #146 from tisnik/e2e-features
LCORE-232: End to end features
2 parents adbb725 + dbb00d2 commit 455623e

3 files changed

Lines changed: 75 additions & 48 deletions

File tree

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
Feature: LLM interface tests
2+
3+
4+
Background:
5+
Given The service is started locally
6+
And REST API service hostname is localhost
7+
And REST API service port is 8080
8+
And REST API service prefix is /v1
9+
10+
11+
Scenario: Check if LLM responds to sent question
12+
Given the system is in default state
13+
When I ask question "Say hello"
14+
Then The status code of the response is 200
15+
And The response should have proper LLM response format
16+
And The response should contain following fragments
17+
| Fragments in LLM response |
18+
| Hello |
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
Feature: REST API tests
2+
3+
4+
Background:
5+
Given The service is started locally
6+
And REST API service hostname is localhost
7+
And REST API service port is 8080
8+
And REST API service prefix is /v1
9+
10+
11+
Scenario: Check if service report proper readiness state
12+
Given the system is in default state
13+
When I access REST API endpoint "readiness" using HTTP GET method
14+
Then The status code of the response is 200
15+
And The body of the response has the following schema
16+
"""
17+
{
18+
"ready": "bool",
19+
"reason": "str"
20+
}
21+
"""
22+
And The body of the response is the following
23+
"""
24+
{"ready": true, "reason": "service is ready"}
25+
"""
26+
27+
28+
Scenario: Check if service report proper liveness state
29+
Given the system is in default state
30+
When I access REST API endpoint "liveness" using HTTP GET method
31+
Then The status code of the response is 200
32+
And The body of the response has the following schema
33+
"""
34+
{
35+
"alive": "bool"
36+
}
37+
"""
38+
And The body of the response is the following
39+
"""
40+
{"alive":true}
41+
"""
42+
43+
44+
Scenario: Check if the OpenAPI endpoint works as expected
45+
Given the system is in default state
46+
When I access endpoint "openapi.json" using HTTP GET method
47+
Then The status code of the response is 200
48+
And The body of the response contains OpenAPI
49+
50+
51+
Scenario: Check if info endpoint is working
52+
Given the system is in default state
53+
When I access REST API endpoint "info" using HTTP GET method
54+
Then The status code of the response is 200
55+
And The body of the response contains name
56+
And The body of the response contains version

tests/e2e/features/smoketests.feature

Lines changed: 1 addition & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -12,51 +12,4 @@ Feature: Smoke tests
1212
Given the system is in default state
1313
When I access endpoint "/" using HTTP GET method
1414
Then The status code of the response is 200
15-
16-
17-
Scenario: Check if service report proper readiness state
18-
Given the system is in default state
19-
When I access REST API endpoint "readiness" using HTTP GET method
20-
Then The status code of the response is 200
21-
And The body of the response has the following schema
22-
"""
23-
{
24-
"ready": "bool",
25-
"reason": "str"
26-
}
27-
"""
28-
And The body of the response is the following
29-
"""
30-
{"ready": true, "reason": "service is ready"}
31-
"""
32-
33-
34-
Scenario: Check if service report proper liveness state
35-
Given the system is in default state
36-
When I access REST API endpoint "liveness" using HTTP GET method
37-
Then The status code of the response is 200
38-
And The body of the response has the following schema
39-
"""
40-
{
41-
"alive": "bool"
42-
}
43-
"""
44-
And The body of the response is the following
45-
"""
46-
{"alive":true}
47-
"""
48-
49-
50-
Scenario: Check if the OpenAPI endpoint works as expected
51-
Given the system is in default state
52-
When I access endpoint "openapi.json" using HTTP GET method
53-
Then The status code of the response is 200
54-
And The body of the response contains OpenAPI
55-
56-
57-
Scenario: Check if info endpoint is working
58-
Given the system is in default state
59-
When I access REST API endpoint "info" using HTTP GET method
60-
Then The status code of the response is 200
61-
And The body of the response contains name
62-
And The body of the response contains version
15+
And Content type of response should be set to "text/html"

0 commit comments

Comments
 (0)