Commit Graph

451 Commits

Author SHA1 Message Date
William Boman 18259219d7 add .editorconfig file 2015-09-08 01:42:23 +01:00
Josh Hagins 32364632be Include Hbc::Staged module in Hbc::DSL::Preflight 2015-09-05 13:41:46 -04:00
Josh Hagins c0ed120631 Expand tilde in uninstall :delete 2015-08-02 20:25:15 -04:00
Josh Hagins 4921567379 Add specs for Staged module helpers to uninstall_preflight_test 2015-08-02 01:41:29 -04:00
Josh Hagins 4e12c8a84c Reorder postflight specs
Put specs for methods inherited from the Staged module before those
specific to Postflight.
2015-08-02 01:40:27 -04:00
Josh Hagins c38110bcec Teach set_permissions and set_ownership to accept multiple paths 2015-08-02 00:54:11 -04:00
Josh Hagins 0acbe2ac46 Add specs for DSL::Postflight#{set_permissions,set_ownership} 2015-08-01 23:43:54 -04:00
Roland Walker 5eec0916c4 attempt to clean up launchctl plists on uninstall
separate `launchctl unload` and comment that this command was
intended for unloading jobs by pathname rather than bundle ID.
Leave that undocumented for now as it is untested.
2015-07-26 16:52:05 -04:00
Andrew Kitchen 8e7a958b6f Allows accessibility entry to be updated if previously installed 2015-06-07 09:18:36 -07:00
Josh Hagins 37f42f90df Report test coverage with coveralls 2015-03-17 21:20:41 -04:00
Josh Hagins d3ba0471e0 Add rubocop config files to layout_test.rb 2015-03-06 19:08:10 -05:00
Paul Hinze b1d621503d internal: spec-ify SystemComand tests 2015-02-08 09:17:23 -06:00
Roland Walker add0279512 Merge pull request #9478 from caskroom/rename-cleanup-cli-option
cli: [refactor] rename outdated option internally
2015-02-07 19:12:13 -05:00
Paul Hinze 5bbba24bf9 cli: [refactor] rename outdated option internally
The `Hbc.outdated` boolean was in the way of my implementation of an
`outdated` scope for `brew cask outdated`, so I took the opportunity to:

 * rename the flag internally to `cleanup_outdated`
 * move the cleanup tests over to rspec and rework them to test in a
   stubbed cleanroom environment
 * refactor the implementation of cleanup to make it a bit more
   testable - most importantly: inject the cache location and outdated
   config dependencies instead of looking them up from constants

Note that there's no change to the user-facing interface, it's still

```
brew cask cleanup --outdated
```
2015-02-07 18:06:51 -06:00
Paul Hinze 63d748e14c core: [refactor] separate Hbc::Cask from Hbc
Hbc is the namespace, Hbc::Cask is the object representing a Cask

One step on the path to reducing the surface area of the God-object
we've grown over the years. :)
2015-02-07 16:37:32 -06:00
Radek Simko 6b3146aed6 binary_test (minitest) -> binary_spec (rspec) 2015-01-24 20:01:54 +00:00
Vítor Galvão 078f0b0300 removed alfred support 2015-01-13 17:49:32 +00:00
ndr d5722ee079 Merge pull request #8751 from vitorgalvao/remove-widget-support
Remove support for widgets
2015-01-11 12:29:00 +00:00
Vítor Galvão 529bd801e4 Removed support for widgets
Closes #2206.
2015-01-08 19:51:15 +00:00
Roland Walker b40b0c99e1 strip constants from homebrew-fork global.rb
and corresponding testing_env.rb.
* recast HOMEBREW_BREW_FILE as Hbc.homebrew_executable,
  defined in Hbc::Locations
* recast HOMEBREW_REPOSITORY as Hbc.homebrew_repository
* recast HOMEBREW_PREFIX as Hbc.homebrew_prefix
* remove HOMEBREW_LIBRARY
* recast existing Hbc.tapspath as Hbc.homebrew_tapspath
  to match new methods

fixes #8705
2015-01-07 09:09:53 -05:00
Roland Walker 202d6019f8 Move all code under an Hbc:: namespace
* convert existing Cask:: namespace to Hbc::
* move Homebrew-fork code under Hbc::
* move freestanding classes such as Tty and TopologicalHash under Hbc::
* recast HOMEBREW_CASK_ constants as HBC_
* modify our Homebrew Formula for backward compatibility
* devscripts and dev docs
2015-01-02 07:27:03 -05:00
Roland Walker 36b8903a36 flatten homebrew-fork and move it under vendor/lib
* remove transitional modifications to $LOAD_PATH
* all require statements are now explicit about loading from homebrew-fork
2014-12-31 07:57:18 -05:00
Roland Walker 43ab87b480 Merge pull request #8539 from rolandwalker/incorporate_homebrew_macos
incorporate a modified homebrew-fork `OS::Mac` into our codebase as `Cask::MacOS`
2014-12-30 17:16:24 -05:00
Roland Walker 13085c7e26 incorporate homebrew-fork OS::Mac as Cask::MacOS
temporarily define ::MacOS = Cask::MacOS pending updates
to the DSL (it should be visible at the top level only
within Casks.)
2014-12-30 11:29:46 -05:00
Roland Walker ec89e5d26b recast class OS::Mac::Version as OS::Mac::Release 2014-12-30 11:20:21 -05:00
Roland Walker 74b46f7e92 Check for libpng to assure X11 detection
Based on Homebrew's xquartz.rb.  Improves Yosemite specifically.
Fixes #8483
2014-12-30 09:59:28 -05:00
ndr 68d7901e44 Add tests for depends_on :cask 2014-12-29 17:47:55 +00:00
Roland Walker cc84f6ecd5 don't monkeypatch MacOS#release
* complete transition from MacOS#version to MacOS#release
  throughout backend code
* recast related constants and comments as "release" instead
  of "version", and "point release" instead of "full version"
2014-12-27 09:19:38 -05:00
ndr a944a5a69f Actually test for multiple `depends_on :formula` 2014-12-26 21:39:39 +00:00
Roland Walker 05d6afa2ac remove homebrew-fork Pathname#/ monkeypatch
in favor of ordinary Pathname#join.  This was already the rule
for our codebase except for some areas of the test suite.
2014-12-26 11:06:34 -05:00
Roland Walker 05690689bc Remove homebrew-fork Checksum class and refactor
* perform actual checksum calculation within download.rb
* use an accessor named sha256 instead of sums for checksum data
* migrate checksum-specific exceptions out of homebrew-fork
2014-12-23 11:08:45 -05:00
Roland Walker 13391af9a9 Merge pull request #8318 from rolandwalker/explicit_ruby_2_requirement
explicitly require Ruby 2.0 at all entry points
2014-12-22 07:20:00 -05:00
Roland Walker 22dc95872c add license stanza to test Cask
to make tests pass after requiring `license`
2014-12-20 11:34:20 -05:00
Roland Walker 140613cbb5 update license comment in brew cask create 2014-12-20 10:35:28 -05:00
Roland Walker 62c2c83639 explicitly require Ruby 2.0 at all entry points
to give a more informative error
2014-12-20 10:25:56 -05:00
Roland Walker 68f1c782a6 port PrettyListing class from Homebrew-fork
and simplify it considerably
2014-12-17 07:33:06 -05:00
Roland Walker 6c41fe493b remove docs and code relevant to Ruby 1.8 compat 2014-12-16 08:50:33 -05:00
Roland Walker 1a238777ee Merge pull request #8089 from rolandwalker/homebrew_separation
Separate the Ruby backend from Homebrew + Require Ruby 2.x
2014-12-16 07:51:37 -05:00
Roland Walker d2a0634ed7 remove testing on Ruby 1.8 and 1.9 2014-12-16 07:23:58 -05:00
Radek Simko 6bce46d2f2 Test options made consistent and documented 2014-12-14 13:16:10 +01:00
Roland Walker 32eca2e634 use homebrew-fork within test environment 2014-12-13 13:13:47 -05:00
Claudia e3c617b6f4 When handling errors or missing methods, the CLI now suggests updating
This helps cut trivial issues that would be easily fixable by doing `brew update && …`.
2014-12-12 19:50:19 +01:00
Roland Walker e5d4765135 Merge pull request #7933 from rolandwalker/comment_unknown_license
mark `license :unknown` with explicit todo comment
2014-12-10 08:42:18 -05:00
Roland Walker b3836f581d recast info_plist as info_plist_file 2014-12-09 10:47:23 -05:00
Roland Walker 568a8229c3 mark license :unknown with explicit todo comment 2014-12-09 07:48:45 -05:00
Roland Walker 5036750355 Merge pull request #7854 from rolandwalker/accessibility_stanza
DSL: add `accessibility_access` stanza
2014-12-08 19:24:19 -05:00
Roland Walker 82826b2687 DSL: add `accessibility_access` stanza
* accepts a Boolean value
* replaces the never-documented `postflight` methods `enable_accessibility_access` /
 `disable_accessibility_access` (`remove_accessibility_access`)
* declarative: unlike the `postflight` approach, does not have to be
  invoked in two places
* de-document obsolete form `caveats` / `assistive_devices`
* bump Travis seed to avoid false test failures
2014-12-08 19:17:19 -05:00
Claudia 5db030e742 Add reason for skipping syntax tests
This might help debug issues like the failing Travis build in PR #7895.
2014-12-08 16:52:19 +01:00
Roland Walker daaf5ad89b missing stubs
can't hurt
2014-12-08 10:32:18 -05:00
Roland Walker 2e71e5110d remove newlines from runtime bundle IDs
* create `staged_test.rb` for testing staged Casks
* test an actual staged Cask rather than mocking
2014-12-08 10:32:18 -05:00