File tree 1 file changed +9
-2
lines changed
1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -13,13 +13,20 @@ function remove_all {
13
13
gem uninstall --all --force $1
14
14
}
15
15
16
+ function assert_sqlite_version_matches {
17
+ ruby -r sqlite3 -e ' \
18
+ puts "compiled #{SQLite3::SQLITE_VERSION} / loaded #{SQLite3::SQLITE_LOADED_VERSION}"; \
19
+ raise("sqlite version mismatch") unless SQLite3::SQLITE_VERSION == SQLite3::SQLITE_LOADED_VERSION; \
20
+ '
21
+ }
22
+
16
23
function test_installation {
17
24
gem=$1
18
25
19
26
# test installation
20
27
remove_all sqlite3
21
28
gem install $gem
22
- ruby -r sqlite3 -e ' pp SQLite3::SQLITE_VERSION, SQLite3::SQLITE_LOADED_VERSION '
29
+ assert_sqlite_version_matches
23
30
24
31
if [[ $gem =~ sqlite3-[^-]* \. gem ]] ; then
25
32
# test installation against system libs without mini_portile, linux distro repackagers
@@ -36,7 +43,7 @@ function test_installation {
36
43
# test installation against system libs
37
44
remove_all sqlite3
38
45
gem install $gem -- --enable-system-libraries
39
- ruby -r sqlite3 -e ' pp SQLite3::SQLITE_VERSION, SQLite3::SQLITE_LOADED_VERSION '
46
+ assert_sqlite_version_matches
40
47
fi
41
48
}
42
49
You can’t perform that action at this time.
0 commit comments