Commit Graph

35 Commits

Author SHA1 Message Date
Kyrylo Silin 9732805a74 Fix failing build on 2.4 & 2.5
Example failure: https://github.com/pry/pry/runs/3010680604

```
ArgumentError: wrong number of arguments (given 4, expected 1)
    /home/runner/work/pry/pry/vendor/bundle/ruby/2.4.0/gems/psych-4.0.1/lib/psych.rb:323:in `safe_load'
```

I am not sure what exactly causes the failure but deleting simplecov dependency
fixes (I guess?) this problem.
2021-07-09 23:10:43 +03:00
Kyrylo Silin 5c31c28ba2 Gemfile: bump rspec & rspec-expectations to v3.10 2021-07-04 23:00:06 +03:00
taki a295910dad Update rake to suppress the warning 2020-03-08 00:32:06 +09:00
Kyrylo Silin 18c45d26c5 rubocop: enable the Style/FrozenStringLiteralComment cop
This will greatly ease Pry support on Ruby 3.0 (when it's out).
2019-05-08 00:13:17 +03:00
Kyrylo Silin 244e4776f9 Gemfile: lock rspec-expectations to v3.8.2
v3.8.2 has a bug on Ruby 1.9.3:
https://github.com/rspec/rspec-expectations/issues/1113

```
TypeError: bind argument must be an instance of Kernel
```

Lock for now, unlock when (if) fixed version is released.
2019-04-28 20:34:56 +03:00
Kyrylo Silin 869ceccf0a Bump rubocop to v0.66.0 and update rubocop_todo 2019-03-21 00:51:57 +02:00
Kyrylo Silin 7c091f2fcb Delete the `gist` command
This command was moved to the [pry-jist][1] plugin. Pry allows good
extensibility and this command doesn't feel like something that should be in Pry
Core. I suspect not many people use it, let alone know about it.

The concept of optional dependencies also feels awkward (the `gist` gem). It's a
strong indication that the command should be moved outside Pry Core (or we
should just depend on `gist`).

[1]: https://github.com/pry/pry-jist
2019-03-12 01:44:37 +02:00
Kyrylo Silin f0ec14c5c7 Configure SimpleCov properly
* Update the requirement to latest version
* Make sure we actually *check* code coverage. Previously, we were only checking
  files in `spec/`, but not we also check `lib/`
2019-03-08 00:50:48 +02:00
Kyrylo Silin cb5eaab409 Gemfile: remove groups
We plan to use SimpleCov and Bundler.require gets in the way. Without it Gemfile
groups are useless, so I am removing them.

I am also removing the silly `Bundler/OrderedGems` cop, one of the most useless
cops you can add.
2019-03-08 00:46:50 +02:00
Kyrylo Silin 4956376f13 rubocop: fix offences of the Metrics/LineLength cop
I realise that some code might be less readable now, but now that we set a good
default limit, we protect the codebase from further mess. It's important to do
this to prevent adding more mess to already messy code that we have. :doctor:
2019-03-03 17:37:58 +02:00
Kyrylo Silin 39fa8a9fc6 rubocop: fix offences of the Style/IfUnlessModifier cop 2019-03-02 11:03:54 +02:00
Kyrylo Silin 3d45a6e562 Bump rubocop to v0.65.0 and generate config 2019-02-24 19:58:59 +02:00
yui-knk 3ee35f3abd Update rspec to 3.8.0 2018-12-12 18:48:39 +09:00
Kyrylo Silin f76688eb6d Gemfile: delete gems that were needed for Guard
`rb-inotify` has a dependency on `ffi`, which fails to compile on Ruby 1.9.3
while running on CircleCI. I don't think anyone who develops Pry (seems to be
just me so far) uses Guard in their worfklow. Our repo is missing an obligatory
Guardfile, too, which makes me think it's a very safe change to make (rather
than wasting time with`ffi` and CircleCI).
2018-10-16 03:57:06 +08:00
Kyrylo Silin f33d82779a rubocop: fix offences of the Style/HashSyntax cop 2018-10-13 03:09:29 +08:00
Kyrylo Silin 4cc13f9a40 rubocop: fix offences of the Layout/ExtraSpacing cop 2018-10-13 00:54:00 +08:00
Kyrylo Silin 743b905c81 Drop support for Rubinius
Fixes #1775 (Drop support for Rubinius)

I am amazed how many hacks we've had just to support Rubinius. It feels good to
be able to remove them and reduce the complexity of the codebase.
2018-10-07 00:58:53 +08:00
Kyrylo Silin 9ffa460548 Gemfile: add rubocop 0.59.2 and lock it
Rubocop is a really nice tool when configured properly. A lot of default rules
are very opinionated but the good thing is that it's very easy to disable them.
With help of Rubocop I'd like to improve the quality of Pry's code.
2018-10-06 20:07:25 +08:00
Fernando Seror Garcia 3bd43b9db4 Update RSpec version to 3.7 (#1712) 2017-11-17 22:03:55 +01:00
robert fdccded0ef fix failing specs.
revert to rspec ~> 3.4.0, and simplecov ~> 0.8.0.
rspec 3.5.0 causes random test failures in the test suite.
simplecov 0.12.0 cannot be installed on ruby 1.9 or earlier.
2016-07-09 02:57:28 +01:00
Josh Cheek 144d32e1d6 Switch test suite to RSpec
Removes Bacon and Mocha

Reasoning explained in this comment: https://github.com/pry/pry/issues/277#issuecomment-51708712

Mostly this went smoothly. There were a few errors that I fixed along
the way, e.g. tests that were failing but for various reasons still
passed. Should have documented them, but didn't think about it until
very near the end. But generaly, I remember 2 reasons this would happen:
`lambda { raise "omg" }.should.raise(RuntimeError, /not-omg/)` will pass
because the second argument is ignored by Bacon. And `1.should == 2`
will return false instead of raising an error when it is not in an it
block (e.g. if stuck in a describe block, that would just return false)

The only one that I felt unsure about was spec/helpers/table_spec.rb
`Pry::Helpers.tablify_or_one_line('head', %w(ing)).should == 'head: ing'`
This is wrong, but was not failing because it was in a describe block
instead of an it block.  In reality, it returns `"head: ing\n"`,
I updated the test to reflect this, though I don't know for sure
this is the right thing to do

This will fail on master until https://github.com/pry/pry/pull/1281 is merged.
This makes https://github.com/pry/pry/pull/1278 unnecessary.
2014-08-10 17:37:21 -06:00
Conrad Irwin f27e718cfe Move back to 'gist' gem 2014-04-27 22:24:20 -07:00
robert a550491fca unbreak pry builds on < ruby 2.1.1 2014-04-27 14:13:24 -07:00
Robert Gleeson 89666001da support deprecated method for HEAD support with pry-doc.
closes #1152.
related to #1136 but `? File.exists?` is still not showing me documentation.
thanks to @yui-knk for finding the bug & providing a solution.
2014-03-23 14:16:08 +01:00
Robert Gleeson 1c6a145ba7 remove attempt at bond support from pry and move to `pry-bond` project.
https://github.com/johnny5-/pry-bond project adds the enable-bond! and disable-bond! commands,
as well as other features, that enhance the pry&bond experience and make it easier to use and
setup without a manual effort.

see #1165
closes #1160
2014-03-17 09:37:23 +01:00
Robert Gleeson f27802fec4 add `yard` to Gemfile 2014-03-16 11:17:33 +01:00
Robert Gleeson 7e3933e848 use false literal in place of string 2014-03-15 01:57:30 +01:00
Robert Gleeson 45cbc55c9f move development dependencies to Gemfile, & use Bundler.require(). 2014-03-15 01:50:21 +01:00
Robert Gleeson 7d0a8e3513 use 'platform' on rubinius (over RbConfig) in Gemfile. 2014-01-26 21:33:03 +01:00
Ryan Fitzgerald 3e31d01d0b Add rubysl-prettyprint to Gemfile for rbx 2013-11-23 18:23:34 -08:00
Ryan Fitzgerald eb150b71d7 Fix specs on rbx-2.1.0 2013-11-23 18:11:29 -08:00
☈king 552b7e18e5 Avoid warning with warny rubygems 2013-02-26 07:27:51 -06:00
☈king 9e6269c1da Dev dep on 'jist' + better Guard deps 2012-12-06 22:45:07 -06:00
Ryan Fitzgerald 981f12ddc2 Add simple Guardfile 2012-09-08 20:27:41 -07:00
Shawn Anderson f87c54bd79 added bundler gemfile 2011-09-13 11:39:04 -04:00