Advertisement
Guest User

Untitled

a guest
Jan 3rd, 2017
144
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.42 KB | None | 0 0
  1. MBPs-MacBook-Pro:pyenv rhemon$ bats test
  2. ✓ default version
  3. ✓ doesn't read version from non-pyenv repo
  4. ✓ reads version from git repo
  5. ✓ prints default version if no tags in git repo
  6. ✓ commands
  7. ✓ commands --sh
  8. ✓ commands in path with spaces
  9. ✓ commands --no-sh
  10. ✓ command with no completion support
  11. ✓ command with completion support
  12. ✓ forwards extra arguments
  13. ✓ fails with invalid version
  14. ✓ fails with invalid version set from file
  15. ✓ completes with names of executables
  16. ✓ carries original IFS within hooks
  17. ✓ forwards all arguments
  18. ✓ supports python -S <cmd>
  19. ✓ default
  20. ✓ read PYENV_ROOT/version
  21. ✓ set PYENV_ROOT/version
  22. ✓ fail setting invalid PYENV_ROOT/version
  23. ✓ without args shows summary of common commands
  24. ✓ invalid command
  25. ✓ shows help for a specific command
  26. ✓ replaces missing extended help with summary text
  27. ✓ extracts only usage
  28. ✓ multiline usage section
  29. ✓ multiline extended help section
  30. ✓ prints usage help given no argument
  31. ✓ prints list of hooks
  32. ✓ supports hook paths with spaces
  33. ✓ resolves relative paths
  34. ✓ resolves symlinks
  35. ✓ creates shims and versions directories
  36. ✓ auto rehash
  37. ✓ setup shell completions
  38. ✓ detect parent shell
  39. ✓ detect parent shell from script
  40. ✓ setup shell completions (fish)
  41. ✓ fish instructions
  42. ✓ option to skip rehash
  43. ✓ adds shims to PATH
  44. ✓ adds shims to PATH (fish)
  45. ✓ can add shims to PATH more than once
  46. ✓ can add shims to PATH more than once (fish)
  47. ✓ outputs sh-compatible syntax
  48. ✓ outputs fish-specific syntax (fish)
  49. ✓ no version
  50. ✓ local version
  51. ✓ discovers version file in parent directory
  52. ✓ ignores PYENV_DIR
  53. ✓ sets local version
  54. ✓ changes local version
  55. ✓ unsets local version
  56. ✓ prefix
  57. ✓ prefix for invalid version
  58. ✓ prefix for system
  59. ✓ prefix for system in /
  60. ✓ prefix for system in /
  61. ✓ prefix for invalid system
  62. ✓ blank invocation
  63. ✓ invalid command
  64. ✓ default PYENV_ROOT
  65. ✓ inherited PYENV_ROOT
  66. ✓ default PYENV_DIR
  67. ✓ inherited PYENV_DIR
  68. ✓ invalid PYENV_DIR
  69. ✓ adds its own libexec to PATH
  70. ✓ adds plugin bin dirs to PATH
  71. ✓ PYENV_HOOK_PATH preserves value from environment
  72. ✓ PYENV_HOOK_PATH includes pyenv built-in plugins
  73. ✓ prefixes
  74. ✓ should use dirname of file argument as PYENV_DIR
  75. ✓ should follow symlink of file argument (#379, #404)
  76. ✓ empty rehash
  77. ✓ non-writable shims directory
  78. ✓ rehash in progress
  79. ✓ creates shims
  80. ✓ removes stale shims
  81. ✓ binary install locations containing spaces
  82. ✓ carries original IFS within hooks
  83. ✓ sh-rehash in bash
  84. ✓ sh-rehash in fish
  85. ✓ no shell version
  86. ✓ shell version
  87. ✓ shell version (fish)
  88. ✓ shell unset
  89. ✓ shell unset (fish)
  90. ✓ shell change invalid version
  91. ✓ shell change version
  92. ✓ shell change version (fish)
  93. ✓ no shims
  94. ✓ shims
  95. ✓ shims --short
  96. ✓ fails without arguments
  97. ✓ fails for invalid file
  98. ✓ fails for blank file
  99. ✓ reads simple version file
  100. ✓ ignores leading spaces
  101. ✗ reads only the first word from file
  102. (from function `assert_equal' in file test/test_helper.bash, line 65,
  103. from function `assert_output' in file test/test_helper.bash, line 74,
  104. from function `assert_success' in file test/test_helper.bash, line 49,
  105. in test file test/version-file-read.bats, line 41)
  106. `assert_success "3.3.5"' failed
  107. expected: 3.3.5
  108. actual: 3.3.5:2.7.6:hi
  109. ✗ loads *not* only the first line in file
  110. (from function `assert_equal' in file test/test_helper.bash, line 65,
  111. from function `assert_output' in file test/test_helper.bash, line 74,
  112. from function `assert_success' in file test/test_helper.bash, line 49,
  113. in test file test/version-file-read.bats, line 50)
  114. `assert_success "2.7.6:3.3.5"' failed
  115. expected: 2.7.6:3.3.5
  116. actual: 2.7.6:one:3.3.5:two
  117. ✓ ignores leading blank lines
  118. ✓ handles the file with no trailing newline
  119. ✓ ignores carriage returns
  120. ✓ invocation without 2 arguments prints usage
  121. ✓ setting nonexistent version fails
  122. ✓ writes value to arbitrary file
  123. ✓ detects global 'version' file
  124. ✓ prints global file if no version files exist
  125. ✓ in current directory
  126. ✓ in parent directory
  127. ✓ topmost file has precedence
  128. ✓ PYENV_DIR has precedence over PWD
  129. ✓ PWD is searched if PYENV_DIR yields no results
  130. ✓ finds version file in target directory
  131. ✓ fails when no version file in target directory
  132. ✓ no version selected
  133. ✓ system version is not checked for existence
  134. ✓ PYENV_VERSION can be overridden by hook
  135. ✓ carries original IFS within hooks
  136. ✓ PYENV_VERSION has precedence over local
  137. ✓ local file has precedence over global
  138. ✓ missing version
  139. ✓ one missing version (second missing)
  140. ✓ one missing version (first missing)
  141. ✓ one missing version (without stderr)
  142. ✓ version with prefix in name
  143. ✓ reports global file even if it doesn't exist
  144. ✓ detects global file
  145. ✓ detects PYENV_VERSION
  146. ✓ detects local file
  147. ✓ reports from hook
  148. ✓ carries original IFS within hooks
  149. ✓ doesn't inherit PYENV_VERSION_ORIGIN from environment
  150. ✓ no version selected
  151. ✓ set by PYENV_VERSION
  152. ✓ set by local file
  153. ✓ set by global file
  154. ✓ set by PYENV_VERSION, one missing
  155. ✓ set by PYENV_VERSION, two missing
  156. ✓ set by PYENV_VERSION, one missing (stderr filtered)
  157. ✓ no versions installed
  158. ✓ not even system python available
  159. ✓ bare output no versions installed
  160. ✓ single version installed
  161. ✓ single version bare
  162. ✓ multiple versions
  163. ✓ indicates current version
  164. ✓ bare doesn't indicate current version
  165. ✓ globally selected version
  166. ✓ per-project version
  167. ✓ ignores non-directories under versions
  168. ✓ lists symlinks under versions
  169. ✓ doesn't list symlink aliases when --skip-aliases
  170. ✓ finds versions where present
  171. ✓ outputs path to executable
  172. ✓ searches PATH for system version
  173. ✓ searches PATH for system version (shims prepended)
  174. ✓ searches PATH for system version (shims appended)
  175. ✓ searches PATH for system version (shims spread)
  176. ✓ doesn't include current directory in PATH search
  177. ✓ version not installed
  178. ✓ versions not installed
  179. ✓ no executable found
  180. ✓ no executable found for system version
  181. ✓ executable found in other versions
  182. ✓ carries original IFS within hooks
  183. ✓ discovers version from pyenv-version-name
  184.  
  185. 168 tests, 2 failures
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement