summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Fix ruby < 2.0 spec compatibilityaa-required-ruby-versionsSamuel Giddins2016-07-111-1/+1
|
* Update specs for using gem_repo2 which has rack 1.2Samuel Giddins2016-07-102-2/+2
|
* Disallow updating gem_repo1 in the specsSamuel Giddins2016-07-106-19/+23
|
* [Resolver] Ensure that spec.required_ruby_version exists before using itSamuel Giddins2016-07-101-1/+7
|
* [Fetcher] Pass metadata when constructing EndpointSpecificationsSamuel Giddins2016-07-101-2/+2
|
* [Rakefile] Don’t print to stderr when not inside of RubyGemsSamuel Giddins2016-07-101-1/+1
|
* flatten rspec block nesting a bitAndre Arko2016-07-101-111/+109
|
* respect required_ruby_versions when presentAndre Arko2016-07-102-20/+38
| | | | | Not only does this test mean that we’re sure the method works, I like how the method is structured now a lot better too :grin:
* Auto merge of #4676 - chrismo:conservative_updates, r=segiddinsHomu2016-07-0913-15/+674
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conservative updates A port of bundler-patch to bundler proper. Core team questions: - [x] bundler-patch also works in vulnerable gem updates based on ruby-advisory-db content. I presume the core team would consider this out of scope for Bundler proper? I probably would, and there's no reason bundler-patch couldn't continue to exist as a plugin with this behavior. - [x] "resolves foo only to latest patch - changing dependency case" - more comments on that spec. It's a weird edge case. Hopefully the specs and comments make it clear. - [x] Name of new class: GemVersionPromoter. It's gone through a few renames already and every option I think of I hate now :) - [x] The `--minimal` flag is also something bundler-patch has that has debatable value. Would love to hear opinions on it and could be easily swayed to remove it or keep it. If I'm on 1.0.1, and both 1.0.2 and 1.0.15 exist, `--minimal` will resolve to `1.0.2` instead of the latest `1.0.15`. Dunno if there's value in that. - [x] even without `--strict` mode, this code will _remove_ older versions from the options handed back to Molinillo (in `--patch` and `--minor` cases). This is a weird case, but I have seen `bundle update` proper regress a gem version backwards if its parent gem changed to an older dependency (I guess in a bug fix case). I'm ok with this, but it could be considered an inconsistency with the default `--major` case. - [x] if we roll this out first as an undocumented feature, do we require a config option to toggle it on? We wouldn't have to have one, none of the new behavior will kick in until a new flag (`--patch` or `--minor`) is passed. --- Notes for issues to create that could be handled separately after this PR, esp. if we release undocumented/unsupported to begin with. - Updating `outdated` to use the new flags and resolution - adding some warnings when dependent updates go past --patch or --minor level (with an instruction to use --strict if they don’t want that) - adding a warning when an unlocked gem doesn't move (possibly w/ a reason why?). the lack of feedback otherwise can be disconcerting, like "did I not do it right?" - possibly adding a dry-run flag - though after looking at that today, that would make the most sense inside Installer, and make that flag an option for both install and update (drilling through all of the calls to push that option in looks like it would be annoying). - man page documentation
| * Don't parse empty Lockfile during GVP initchrismo2016-07-083-10/+39
| | | | | | | | | | | | | | | | Not a common case, but glitch is triggered by new plugin integration tests when there's no Gemfile or .bundle directory. A GemfileNotFound exception is raised deeper down the call stack trying to access the cache_path when executed in a non-bundler dir. That case apparently is legit for plugins.
| * Raise message on multiple optionschrismo2016-07-082-2/+11
| |
| * Mark pending two failing specs.chrismo2016-07-081-4/+2
| | | | | | | | | | | | | | segiddins and I are agreed there appears to be an issue with Molinillo in these cases, but they are unusual and for now we're looking to do an undocumented release of the new conservative updates, so we can start to get feedback. We'll revisit these cases.
| * Add docs to GemVersionPromoter.chrismo2016-07-082-23/+60
| | | | | | | | | | Also some pending specs cleanup. These may be added as new issues and addressed later.
| * Support for reverting to older versions.chrismo2016-07-083-10/+56
| | | | | | | | | | | | | | | | | | | | | | | | This is the first behavior change from bundler-patch. Used to be older versions would never be an option, but Bundler proper has always supported this (if necessary to resolve the dependency tree) and there can be some legit cases for doing this. The `--strict` flag could be used to override this behavior, but I'm running into a Molinillo behavior that I'm not sure is correct, so the specs involving the strict option are failing right now. I'm going to push so @segiddins and I can discuss.
| * Add some additional GVP specs per TODO.chrismo2016-07-081-5/+19
| | | | | | | | | | When I ported over specs from bundler-patch, I had a TODO on a combination that had no specs, so that's taken care of now.
| * Remove old pending specchrismo2016-07-081-2/+0
| |
| * Hook-up `--strict` option, flesh out update specs.chrismo2016-07-082-32/+53
| | | | | | | | | | Getting caught up on missing update_specs, realized `--strict` flagged wasn't being passed through. Fixed.
| * Mark new options as hiddenchrismo2016-07-081-6/+4
| |
| * No need to dupe cached GVP outputchrismo2016-07-082-17/+1
| | | | | | | | ...now that its output is inside the Resolver's cache.
| * Moved half-arsed debug test to its own testchrismo2016-07-082-2/+12
| |
| * Fix up major support in GVP.chrismo2016-07-082-39/+45
| | | | | | | | | | | | | | | | | | | | If GVP handles the default :major case, it now passes all the specs, but that's a lot of existing functionality to hand off to it at this stage, so I kept in the conditional to just roll with existing results if :major. Got rid of a couple of superfluous begin/end I'd included to make RubyMine auto-format the code in a way that made Rubocop happy.
| * Moved GemVersionPromoter inside search_for cache.chrismo2016-07-085-44/+59
| | | | | | | | | | | | | | | | | | | | In the process I was able to simplify some of the code inside GemVersionPromoter dealing with SpecGroups. I also attempted to implement the :major behavior into GemVersionPromoter as that would eliminate the logic to skip it in `#search_for`, however I ran into some test failures that I need to investigate further, though unit specs are working so far.
| * Cleanup DEBUG var and outputchrismo2016-07-081-5/+4
| |
| * Invalid level in GemVersionPromoter now raises.chrismo2016-07-083-2/+31
| | | | | | | | | | This shouldn't ever surface to the user, would be the result of a coding mistake.
| * Use readers instead of ivarschrismo2016-07-081-7/+6
| |
| * Remove superfluous default value in Resolver initchrismo2016-07-081-1/+1
| |
| * Remove minimal optionchrismo2016-07-084-49/+3
| |
| * Clarified changing dependency specs.chrismo2016-07-085-20/+48
| | | | | | | | | | | | | | A couple of confusing cases that should be clearer now and the differences called out. Details in the spec code and comments. Plus some MODO additions and other pending spec additions.
| * Port GemVersionPromoter specs from bundler-patchchrismo2016-07-082-1/+158
| |
| * Add spec to definition for gem version promoter.chrismo2016-07-084-2/+19
| |
| * Ensure locked_specs provided in unlock all case.chrismo2016-07-083-4/+21
| | | | | | | | | | | | | | | | Another bit brought over from bundler-patch, this code in Definition ensures the GemVersionPromoter has the locked specs it needs in the 'unlock all' case. Everywhere else in Definition, empty @locked_specs means unlock all, but doing conservative updates requires knowing the current locked version so it always needs this list.
| * GemVersionPromoter refactorchrismo2016-07-087-142/+141
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | UpdateOptions which was then renamed to DependencySearch is now called GemVersionPromoter, cuz I can't name this damn class. It's in its own file now, so there's that. I took a shot at moving Resolver#search_for into it, but had naively overlooked a few instance variables and such and it just didn't make as much sense as I'd first envisioned. Probably some other smaller classes in between perhaps. GemVersionPromoter class now caching its results, too, and I moved out the return from it back into Resolver as it made more sense there. As a standalone class, it may make sense to have this actually implement :major sorting, but maybe later.
| * Rename UpdateOptions=>DependencySearchchrismo2016-07-085-13/+21
| |
| * RuboCop fixeschrismo2016-07-085-60/+84
| |
| * 1st pass thorough specs on conservative resolver.chrismo2016-07-084-16/+89
| | | | | | | | | | | | | | | | | | | | Ported over resolver specs from bundler-patch README (which don't match the actual specs for no particular reason other than dev lolz) and expanded on some of the cases after a few weird cases resolved ... a little unexpectedly. They're passing, but some discussion to be had on some of the cases perhaps. See inline spec comments.
| * First resolver spec and bug fix.chrismo2016-07-083-10/+30
| | | | | | | | | | | | | | I stared at that code 2 or 3 times before seeing the obvious bug. Sigh. Anyway - needed to get these resolver specs going sooner or later. Both the first new resolver spec is passing as is the first update_spec spec (plus the pre-existing ones).
| * minor/patch resolution code invokable.chrismo2016-07-084-18/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Prior commit added in the code but it only worked in the default :major case by staying out of the way, so it at least didn't break existing functionality. But the GemsToPatch class hadn't been brought over from bundler-patch yet, so none of the patch/minor code could work as it was referencing an ivar that didn't exist yet. Bundler-patch not only will handle an update to whatever is the latest patch/minor version, but will also handle an update to a version specified in an advisory from ruby-advisory-db. At this point I don't believe we'll be adding the advisory behavior to Bundler proper, so this commit can bring over simply the array of gem names being updated without the GemsToPatch class or the extra sorting code that takes a specific version number into account. With these simplifications, the starter update_spec can run without exception, though for some reason it's behaving as if the :minor level were specified, instead of :patch. Rather than keep debugging from an integration level, it's time to start bringing over resolver tests.
| * bundler-patch resolver code ported over.chrismo2016-07-082-3/+109
| | | | | | | | | | | | | | | | | | | | | | Putting all this code into Resolver itself, when it's almost completely isolated, didn't make sense. UpdateOptions was the best place for it, prompting me to think that class needs renaming and see if the current search_for method could be moved into it as well. Except for `index_for` it's a cinch. `install_spec` and `update_spec` are still passing with this addition, first new spec for conservative update isn't yet.
| * UpdateOptions added and passed thru all_the_thingschrismo2016-07-085-18/+34
| | | | | | | | | | | | | | | | | | | | | | First shot adding new update CLI options and passing those through Definition into Resolver where they're needed. I opted for three separate options to reduce typing, vs. a --level [patch|minor|major]. It's a little painful merely extending parameter lists in places, but bigger refactorings prolly be more painful.
| * Starter update_specschrismo2016-07-082-1/+49
| |
* | Auto merge of #4768 - kevintpeng:patch-1, r=segiddinsHomu2016-07-091-1/+1
|\ \ | |/ |/| | | | | | | fix feature request link I noticed the label name was updated.
| * fix feature request link [ci skip]Kevin Peng2016-07-081-1/+1
|/
* Auto merge of #4756 - bundler:seg-silence-tests, r=segiddinsHomu2016-07-061-0/+1
|\ | | | | | | | | | | | | Fix RubyGems printing packaging messages during the specs Closes #4755. My bad!
| * Fix RubyGems printing packaging messages during the specsseg-silence-testsSamuel Giddins2016-07-051-0/+1
| |
* | Auto merge of #4674 - asutoshpalai:plugin, r=segiddinsHomu2016-07-0532-189/+1751
|\ \ | |/ |/| | | | | | | [Plugin] Source plugins Adds source plugin. This is in continuation of #4608.
| * Removed plugin multi option lock spec for 1.8.7Asutosh Palai2016-07-032-4/+3
| |
| * Spec fixes for older versionsAsutosh Palai2016-07-032-2/+2
| |
| * Added unit specs for api#sourceAsutosh Palai2016-07-032-1/+85
| |
| * Mixed SharedHelpers with Plugin::APIAsutosh Palai2016-07-035-20/+20
| |
| * Added to api/sourceAsutosh Palai2016-07-033-1/+39
| |