Skip to content

Commit 2018323

Browse files
committed
chore: fix test script
1 parent 22cfb00 commit 2018323

File tree

1 file changed

+1
-50
lines changed

1 file changed

+1
-50
lines changed

test/test_helper.exs

Lines changed: 1 addition & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -1,54 +1,5 @@
11
# Do not run the SSL tests on Travis
2-
3-
{string, 0} = System.cmd("mongod", ~w'--version')
4-
["db version v" <> version, _] = String.split(string, "\n", parts: 2)
5-
6-
IO.puts("[mongod v#{version}]")
7-
8-
version =
9-
version
10-
|> String.split(".")
11-
|> Enum.map(&elem(Integer.parse(&1), 0))
12-
|> List.to_tuple()
13-
14-
options = [ssl: true, socket: true]
15-
16-
options =
17-
if System.get_env("CI") do
18-
[tag_set: true] ++ options
19-
else
20-
options
21-
end
22-
23-
options =
24-
if version < {3, 4, 0} do
25-
[mongo_3_4: true] ++ options
26-
else
27-
options
28-
end
29-
30-
options =
31-
if version < {3, 6, 0} do
32-
[mongo_3_6: true] ++ options
33-
else
34-
options
35-
end
36-
37-
options =
38-
if version < {4, 2, 0} do
39-
[mongo_4_2: true] ++ options
40-
else
41-
options
42-
end
43-
44-
options =
45-
if version < {4, 3, 0} do
46-
[mongo_4_3: true] ++ options
47-
else
48-
options
49-
end
50-
51-
ExUnit.configure(exclude: options)
2+
ExUnit.configure(exclude: [ssl: true, socket: true])
523
ExUnit.start()
534

545
defmodule MongoTest.Case do

0 commit comments

Comments
 (0)