aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/test/cask/artifact/nested_container_spec.rb
blob: f9cd056f8a4f6f682d0d80a57583a38004cdc3c1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
describe Hbc::Artifact::NestedContainer, :cask do
  describe "install" do
    it "extracts the specified paths as containers" do
      cask = Hbc::CaskLoader.load(cask_path("nested-app")).tap do |c|
        InstallHelper.install_without_artifacts(c)
      end

      cask.artifacts.select { |a| a.is_a?(described_class) }.each do |artifact|
        artifact.install_phase(command: Hbc::NeverSudoSystemCommand, force: false)
      end

      expect(cask.staged_path.join("MyNestedApp.app")).to be_a_directory
    end
  end
end