This repository has been archived by the owner on May 4, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2ceefaf
commit 1b109af
Showing
4 changed files
with
32 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# frozen_string_literal: true | ||
|
||
RSpec.describe MOSAIK::Extractors::Evolution do | ||
subject(:extractor) { described_class.new(options, graph) } | ||
|
||
let(:options) { { directory: MOSAIK.root, logical: 1, contributor: 1 } } | ||
let(:graph) { build(:graph) } | ||
|
||
let(:configuration) { build(:configuration) } | ||
|
||
describe "#validate" do | ||
it "does not raise an error" do | ||
expect { extractor.validate }.not_to raise_error | ||
end | ||
|
||
context "when the directory is not a git repository root" do | ||
let(:options) { { directory: "/tmp" } } | ||
|
||
it "raises an error" do | ||
expect { extractor.validate }.to raise_error MOSAIK::OptionError, "directory is not a git repository" | ||
end | ||
end | ||
end | ||
end |