Skip to content

Commit ede9d4c

Browse files
committed
Tests and refactoring
- Add some basic RSpec tests and run them - Split modules into separate files
1 parent eca3972 commit ede9d4c

File tree

10 files changed

+663
-533
lines changed

10 files changed

+663
-533
lines changed

.github/workflows/tests.yml

+9
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,21 @@ jobs:
1515
export HOMEBREW_DEVELOPER="1"
1616
export HOMEBREW_NO_AUTO_UPDATE=1
1717
brew update-reset
18+
rm -f /usr/local/lib/libcrypto.1.1.dylib /usr/local/lib/libssl.1.1.dylib
1819
brew install mysql
1920
ln -s "$PWD" "/usr/local/Homebrew/Library/Taps/homebrew/homebrew-services"
2021
2122
- name: Run brew style
2223
run: brew style homebrew/services
2324

25+
- name: Install Homebrew/homebrew-services RubyGems
26+
run: |
27+
gem install bundler -v "~>1"
28+
bundle install --jobs 4 --retry 3
29+
30+
- name: Run Homebrew/homebrew-services RSpec tests
31+
run: bundle exec rspec
32+
2433
- name: CI Tests
2534
run: |
2635
# Test start command

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
coverage/

Gemfile

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
source "https://rubygems.org"
2+
3+
group :test do
4+
gem "rspec"
5+
gem "simplecov"
6+
end

Gemfile.lock

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
GEM
2+
remote: https://rubygems.org/
3+
specs:
4+
diff-lcs (1.3)
5+
docile (1.3.2)
6+
json (2.3.0)
7+
rspec (3.9.0)
8+
rspec-core (~> 3.9.0)
9+
rspec-expectations (~> 3.9.0)
10+
rspec-mocks (~> 3.9.0)
11+
rspec-core (3.9.1)
12+
rspec-support (~> 3.9.1)
13+
rspec-expectations (3.9.0)
14+
diff-lcs (>= 1.2.0, < 2.0)
15+
rspec-support (~> 3.9.0)
16+
rspec-mocks (3.9.1)
17+
diff-lcs (>= 1.2.0, < 2.0)
18+
rspec-support (~> 3.9.0)
19+
rspec-support (3.9.2)
20+
simplecov (0.17.1)
21+
docile (~> 1.1)
22+
json (>= 1.8, < 3)
23+
simplecov-html (~> 0.10.0)
24+
simplecov-html (0.10.2)
25+
26+
PLATFORMS
27+
ruby
28+
29+
DEPENDENCIES
30+
rspec
31+
simplecov
32+
33+
BUNDLED WITH
34+
1.17.3

0 commit comments

Comments
 (0)