File tree Expand file tree Collapse file tree 2 files changed +5
-3
lines changed Expand file tree Collapse file tree 2 files changed +5
-3
lines changed Original file line number Diff line number Diff line change 22
22
23
23
TRANSPORT_OPTIONS = { }
24
24
PROJECT_PATH = File . join ( File . dirname ( __FILE__ ) , '..' )
25
+ STACK_VERSION = ENV [ 'STACK_VERSION' ]
25
26
26
27
if ( hosts = ELASTICSEARCH_URL )
27
28
split_hosts = hosts . split ( ',' ) . map do |host |
37
38
if defined? ( TEST_HOST ) && defined? ( TEST_PORT )
38
39
URL = "http://#{ TEST_HOST } :#{ TEST_PORT } "
39
40
40
- if ENV [ ' STACK_VERSION' ] == '8.0.0-SNAPSHOT'
41
+ if STACK_VERSION . match? ( /^8 \. / )
41
42
user = 'elastic' . freeze
42
43
password = 'changeme' . freeze
43
44
ADMIN_CLIENT = Elasticsearch ::Client . new (
76
77
end
77
78
end
78
79
79
- YAML_FILES_DIRECTORY = "#{ PROJECT_PATH } /../tmp/rest-api-spec/test/free"
80
+ YAML_FILES_DIRECTORY = "#{ PROJECT_PATH } /../tmp/rest-api-spec/#{ STACK_VERSION . match? ( /^8 \. / ) ? 'compatTest' : ' test' } /free"
80
81
81
82
SINGLE_TEST = if ENV [ 'SINGLE_TEST' ] && !ENV [ 'SINGLE_TEST' ] . empty?
82
83
test_target = ENV [ 'SINGLE_TEST' ]
Original file line number Diff line number Diff line change 23
23
24
24
TRANSPORT_OPTIONS = { }
25
25
TEST_SUITE = ENV [ 'TEST_SUITE' ] . freeze || 'platinum'
26
+ STACK_VERSION = ENV [ 'STACK_VERSION' ]
26
27
27
28
if hosts = ENV [ 'TEST_ES_SERVER' ] || ENV [ 'ELASTICSEARCH_HOSTS' ]
28
29
split_hosts = hosts . split ( ',' ) . map do |host |
65
66
end
66
67
end
67
68
68
- YAML_FILES_DIRECTORY = "#{ PROJECT_PATH } /tmp/rest-api-spec/test/platinum"
69
+ YAML_FILES_DIRECTORY = "#{ PROJECT_PATH } /tmp/rest-api-spec/#{ STACK_VERSION . match? ( /^8 \. / ) ? 'compatTest' : ' test' } /platinum"
69
70
70
71
SINGLE_TEST = if ENV [ 'SINGLE_TEST' ] && !ENV [ 'SINGLE_TEST' ] . empty?
71
72
test_target = ENV [ 'SINGLE_TEST' ]
You can’t perform that action at this time.
0 commit comments