File tree Expand file tree Collapse file tree 3 files changed +6
-2
lines changed
elasticsearch-api/spec/yaml-test-runner Expand file tree Collapse file tree 3 files changed +6
-2
lines changed Original file line number Diff line number Diff line change 6767 env :
6868 RUBY_VERSION : " 3.3"
6969 STACK_VERSION : 8.15.0-SNAPSHOT
70+ ES_YAML_TESTS_BRANCH : 8.15
7071 TRANSPORT_VERSION : " 8.3"
7172 RUBY_SOURCE : " ruby"
7273 TEST_SUITE : " platinum"
Original file line number Diff line number Diff line change @@ -36,6 +36,7 @@ docker run \
3636 --env " BUILDKITE=true" \
3737 --env " TRANSPORT_VERSION=${TRANSPORT_VERSION} " \
3838 --env " STACK_VERSION=${STACK_VERSION} " \
39+ --env " ES_YAML_TESTS_BRANCH=${ES_YAML_TESTS_BRANCH} " \
3940 --volume $repo :/usr/src/app \
4041 --name elasticsearch-ruby \
4142 --rm \
Original file line number Diff line number Diff line change 5555 CLIENT = Elasticsearch ::Client . new ( host : host , transport_options : transport_options )
5656end
5757
58-
5958tests_path = File . expand_path ( './tmp' , __dir__ )
6059
6160logger = Logger . new ( $stdout)
6261logger . level = Logger ::WARN unless ENV [ 'DEBUG' ]
6362
64- Elasticsearch ::Tests ::Downloader ::run ( tests_path )
63+ # If we're running in a release branch, download the corresponding branch for tests
64+ current_branch = `git rev-parse --abbrev-ref HEAD` . strip
65+ branch = current_branch . match ( /[0-9]\. [0-9]+/ ) &.[]( 0 ) || ENV [ 'ES_YAML_TESTS_BRANCH' ] || nil
66+ Elasticsearch ::Tests ::Downloader ::run ( tests_path , branch )
6567Elasticsearch ::Tests ::TestRunner . new ( CLIENT , tests_path , logger ) . run
You can’t perform that action at this time.
0 commit comments