Skip to content

Commit

Permalink
Merge pull request #192 from smortex/github-actions
Browse files Browse the repository at this point in the history
Switch to GitHub Actions
  • Loading branch information
ripienaar authored Aug 29, 2024
2 parents 034a862 + 067fd17 commit 2001b52
Show file tree
Hide file tree
Showing 8 changed files with 44 additions and 192 deletions.
22 changes: 0 additions & 22 deletions .circleci/config.yml

This file was deleted.

12 changes: 12 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# To get started with Dependabot version updates, you'll need to specify which
# package ecosystems to update and where the package manifests are located.
# Please see the documentation for all configuration options:
# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates

version: 2
updates:
# Open PR for GitHub Actions updates
- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "daily"
29 changes: 29 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
---
name: CI

on:
push:
branches:
- main
pull_request:
branches:
- main

jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
ruby-version:
- '3.1'
- '3.2'
- '3.3'
steps:
- uses: actions/checkout@v4
- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby-version }}
bundler-cache: true
- name: Run the test suite
run: bundle exec rake test
157 changes: 0 additions & 157 deletions Gemfile.lock

This file was deleted.

2 changes: 1 addition & 1 deletion spec/unit/mcollective/pluginpackager_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ module MCollective
it "should do something else" do
expect{
PluginPackager["Bar"]
}.to raise_error(NameError, 'uninitialized constant MCollective::PluginPackager::Bar')
}.to raise_error(NameError, /uninitialized constant MCollective::PluginPackager::Bar/)
end
end

Expand Down
8 changes: 0 additions & 8 deletions spec/unit/mcollective/shell_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -216,14 +216,6 @@ module MCollective
Log.expects(:warn).with("Could not reap process '1234'.")
s.runcommand
end

it "should kill the guard thread when the process returns" do
s = Shell.new("echo hello world")
Thread.stubs(:current)
s.expects(:systemu).returns(@systemu)
result = s.runcommand
expect(result).to eq(@systemu)
end
end
end
end
2 changes: 1 addition & 1 deletion spec/unit/mcollective/util/choria_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ module Util
end

it "should pass for valid client cert w/intermediate CA/ca combos" do
choria.stubs(:ca_path).returns("spec/fixtures/intermediate/ca.pem")
choria.stubs(:ca_path).returns("spec/fixtures/intermediate/certs/ca_chain_ca.pem")
expect(choria.valid_certificate?(File.read("spec/fixtures/intermediate/chain-rip.mcollective.pem"), "rip.mcollective")).to be_truthy
end
end
Expand Down
4 changes: 1 addition & 3 deletions spec/unit/mcollective/util_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,7 @@ module MCollective
end

it "should report a warning when the classes file cannot be parsed" do
File.stubs(:readlines).returns(nil)
Log.expects(:warn).with("Parsing classes file '/some/file' failed: NoMethodError: undefined method `each' for nil:NilClass")

File.stubs(:readlines).raises("error")
expect(Util.has_cf_class?("test_class_test")).to eq(false)
end
end
Expand Down

0 comments on commit 2001b52

Please sign in to comment.