Skip to content

Commit

Permalink
Add test showing bulk order issuer
Browse files Browse the repository at this point in the history
  • Loading branch information
rdettai committed Sep 17, 2024
1 parent 740b2ba commit b56483b
Show file tree
Hide file tree
Showing 10 changed files with 37 additions and 32 deletions.
2 changes: 1 addition & 1 deletion quickwit/rest-api-tests/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ running in DEBUG mode is fine.
```

When targeting elasticsearch, the script expects elastic to be running on
`http://localhost:9200`.
`http://localhost:9200` (see [compose script](./docker-compose.yaml)).

In both cases, the test will take care of setting up, ingesting and tearing down the
indexes involved.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,28 +1,25 @@
ndjson:
- index: { "_index": "test-index-not-found", "_id": "1" }
- message: Hello, World!"
- index: { "_index": "test-index-not-found" }
- message: Hello, World!"
- index: { "_index": "test-index" }
- message: Hola, Mundo!
- index: { "_index": "test-index-pattern-777" }
- message: Hola, Mundo!
status_code: 200
expected:
errors: true
items:
- index:
_index: test-index-not-found
_id: "1"
status: 404
error:
index: test-index-not-found
type: index_not_found_exception
reason:
$expect: val.startswith('no such index [test-index-not-found]')
- index:
_index: test-index-not-found
_id: null
status: 404
error:
index: test-index-not-found
type: index_not_found_exception
reason:
$expect: val.startswith('no such index [test-index-not-found]')

_index: test-index
status: 201
- index:
_index: test-index-pattern-777
status: 201
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@ method: DELETE
endpoint: test-index
status_code: null
---
method: DELETE
endpoint: test-index-pattern-777
status_code: null
---
method: PUT
endpoint: test-index
json: {
Expand All @@ -19,3 +23,10 @@ json: {
}
}
}
---
# Only create indexes automatically for specific pattern
method: PUT
endpoint: _cluster/settings
json:
transient:
action.auto_create_index: "test-index-pattern-*"
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,11 @@ status_code: null
---
method: DELETE
api_root: http://localhost:7280/api/v1/
endpoint: indexes/test-index-pattern-777
status_code: null
---
method: DELETE
api_root: http://localhost:7280/api/v1/
endpoint: templates/test-index-template
status_code: null
---
Expand All @@ -31,7 +36,7 @@ json:
version: "0.8"
template_id: test-index-template
index_id_patterns:
- test-index-happy-path*
- test-index-pattern-*
doc_mapping:
mode: dynamic
indexing_settings:
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Reconfigure with the default settings
method: PUT
endpoint: _cluster/settings
json:
transient:
action.auto_create_index: "true"
---
method: DELETE
endpoint: test-index*
status_code: null

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

0 comments on commit b56483b

Please sign in to comment.