diff options
| author | Mike McQuaid | 2017-10-18 09:43:45 +0100 |
|---|---|---|
| committer | GitHub | 2017-10-18 09:43:45 +0100 |
| commit | c7d21dadfef2b1d629c9e7de034cc99afea5b2b4 (patch) | |
| tree | 532f6cb210068cbddaca3efa9c363335237a0cbf /Library/Homebrew/test | |
| parent | c4e8c7906d12399b34188cd3395b8f9d30dc89b3 (diff) | |
| parent | 230c87aff006e36bd65bb6dcc8a3877aad2c9290 (diff) | |
| download | brew-c7d21dadfef2b1d629c9e7de034cc99afea5b2b4.tar.bz2 | |
Merge pull request #3270 from sjackman/os-requirement
Add depends_on :linux and :macos
Diffstat (limited to 'Library/Homebrew/test')
| -rw-r--r-- | Library/Homebrew/test/os_requirement_spec.rb | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/Library/Homebrew/test/os_requirement_spec.rb b/Library/Homebrew/test/os_requirement_spec.rb new file mode 100644 index 000000000..87f86231c --- /dev/null +++ b/Library/Homebrew/test/os_requirement_spec.rb @@ -0,0 +1,18 @@ +require "requirements/linux_requirement" +require "requirements/macos_requirement" + +describe LinuxRequirement do + describe "#satisfied?" do + it "returns true if OS is Linux" do + expect(subject.satisfied?).to eq(OS.linux?) + end + end +end + +describe MacOSRequirement do + describe "#satisfied?" do + it "returns true if OS is macOS" do + expect(subject.satisfied?).to eq(OS.mac?) + end + end +end |
