Commit graph

22 commits

Author SHA1 Message Date
Yamashita, Yuu
83f97ef2b3 Merge remote-tracking branch 'rbenv/master' into rbenv-20180402 2018-04-02 01:46:48 +00:00
Daniel Hahler
a9ca72ab8e test/which.bats: do not export PATH
Otherwise `sed` might not be found later in bats/libexec/bats-exec-test,
in case `/usr/bin` gets removed.
2017-11-20 04:22:05 +01:00
Yamashita, Yuu
41ce3aade2 Merge remote-tracking branch 'rbenv/master' into rbenv-1.0 2016-03-02 01:39:52 +00:00
Jason Karns
0f7a2cad8d Use create_hook helper
Use extracted create_hook helper in tests for:

- exec
- hooks
- rehash
- version-name
- version-origin
- which
2016-01-04 09:14:25 -05:00
Yamashita, Yuu
3031cb9750 Add workaround for test failure on Arch Linux (#480) 2015-12-20 12:29:30 +00:00
Daniel Hahler
03ece82197 Merge remote-tracking branch 'rbenv/master'
Using `git merge rbenv/master -s recursive -X rename-threshold=5%`.

Conflicts:
	README.md
	bin/python-local-exec
	libexec/pyenv
	libexec/pyenv-help
	test/--version.bats
2015-12-14 13:47:11 +01:00
Mislav Marohnić
90373d78b9 Add test for not including current directory in PATH search
Confirms #836
2015-12-14 11:59:01 +01:00
Yamashita, Yuu
8da3749648 Merge remote-tracking branch 'rbenv/master' into rbenv-20151121 2015-11-21 04:21:14 +00:00
Mislav Marohnić
3405c4d03c Fix error message when command is not found for "system" version
If `foo` didn't exist and `RBENV_VERSION=system rbenv which foo` was
called, the error message used to be misleading:

    rbenv: version `system' is not installed

Instead, have the error message simply say that the command was not found.

Fixes #770
2015-11-13 23:10:09 -05:00
Daniel Hahler
e3982fae38 Display version origin with non-installed versions
This is useful as an indicator where it is coming from.
2015-07-17 17:10:33 +02:00
Daniel Hahler
de5c61cd59 Fix "version X is not installed" with multiple PYENV_VERSIONs
This was introduced when merging the rbenv upstream change
(https://github.com/sstephenson/rbenv/commit/6bb7f07d2d).
2014-10-16 02:51:07 +02:00
Daniel Hahler
e82f943174 Merge rbenv's "Isolate rbenv-which tests …" (c69d9a11)
This is the remaining part of
c69d9a1128.

    commit c69d9a1128
    Author: Mislav Marohnić <mislav.marohnic@gmail.com>
    Date:   Mon Oct 13 12:39:47 2014 +0200

        Isolate rbenv-which tests from any `.ruby-version` file on the system

        Having a `.ruby-version` file in any of the parent directories of the
        local clone of rbenv could cause the test suite to fail because it
        wasn't expecting a local version to be set.
2014-10-13 21:20:57 +02:00
Daniel Hahler
bbf8cb4a95 Add test for PYENV_VERSION=3.4:2.7 2014-10-13 21:15:22 +02:00
Daniel Hahler
a1df551bcf Merge tests and remove_from_path from rbenv
This adds the missing parts from the upstream rbenv merge:
f4652fbbf0

- e4cbf04592
- 3ee395f9b5
2014-10-13 21:14:57 +02:00
Mislav Marohnić
c69d9a1128 Isolate rbenv-which tests from any .ruby-version file on the system
Having a `.ruby-version` file in any of the parent directories of the
local clone of rbenv could cause the test suite to fail because it
wasn't expecting a local version to be set.

Fixes #533
2014-10-13 12:39:47 +02:00
Daniel Hahler
e4cbf04592 Improve performance of rbenv-which when RBENV_VERSION=system
This implements removing of the shims path element via bash
substitution, instead of jumping around in all the `$PATH` elements.
2014-10-13 12:26:43 +02:00
Mislav Marohnić
6bb7f07d2d Avoid rbenv-exec calling out to rbenv-version-name twice
Running any shim (and thus `rbenv-exec`) would always execute
`rbenv-version-name` twice: once in `rbenv-exec` and another time in
`rbenv-which`, even though RBENV_VERSION variable would have already
been populated at this point.

Now RBENV_VERSION is respected within `rbenv-which`.
2014-10-13 12:26:43 +02:00
Yamashita Yuu
319721b380 Modify applications and versions for Python 2014-01-03 04:41:23 +09:00
Yamashita Yuu
0965577b93 Import tests from rbenv with sed -e s/rbenv/pyenv/g 2014-01-03 02:06:36 +09:00
Mislav Marohnić
060f141b21 test that IFS in hooks is correct
closes #379
2013-04-16 14:01:43 +02:00
Mislav Marohnić
7fc5f46bbb undo assert_output_lines in tests
It was a dumb idea and it wasn't even implemented perfectly.
2013-04-08 23:16:35 +02:00
Mislav Marohnić
969af1567a add tests for rehash, whence, which 2013-04-08 23:02:30 +02:00