aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/test/test_bundle.rb
blob: 6b040df1dbae885a293976999087fffceba93f5e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
require "helper/integration_command_test_case"

class IntegrationCommandTestBundle < IntegrationCommandTestCase
  def test_bundle
    needs_test_cmd_taps
    setup_remote_tap("homebrew/bundle")
    HOMEBREW_REPOSITORY.cd do
      shutup do
        system "git", "init"
        system "git", "commit", "--allow-empty", "-m", "This is a test commit"
      end
    end

    mktmpdir do |path|
      FileUtils.touch "#{path}/Brewfile"
      Dir.chdir path do
        assert_equal "The Brewfile's dependencies are satisfied.",
          cmd("bundle", "check")
      end
    end
  end
end