tide/tests/_tide_item_ruby.test.fish
Carl Mercier 9252158e4f
Converted chruby to generic ruby (#437)
* Converted chruby to generic ruby

* Attempt at tests

* Only show the Ruby version if current directory has .rb files

* Only show the Ruby version if current directory has .rb files

* Revert "Only show the Ruby version if current directory has .rb files"

This reverts commit 136b02c1fd.

* Refactor

* Removed .tool-versions

* Sort configs

* Sort icons

* Remove pending changes

* Sort for remove_unusable_items

---------

Co-authored-by: Ilan Cosman <ilancosman@gmail.com>
2023-09-13 21:06:56 -07:00

22 lines
357 B
Fish

# RUN: %fish %s
_tide_parent_dirs
function _ruby
_tide_decolor (_tide_item_ruby)
end
set -l ruby_directory (mktemp -d)
cd $ruby_directory
mock ruby --version "echo 'ruby 3.2.0 (2022-12-25 revision a528908271) +YJIT [arm64-darwin22]'"
set -lx tide_ruby_icon
_ruby # CHECK:
touch Gemfile
_ruby # CHECK:  3.2.0
command rm -r $ruby_directory