File tree Expand file tree Collapse file tree 4 files changed +28
-60
lines changed
Expand file tree Collapse file tree 4 files changed +28
-60
lines changed Original file line number Diff line number Diff line change 1+ creating user files in spec/tmp/src
2+ skipped spec/tmp/src/initialize.sh (exists)
3+ skipped spec/tmp/src/download_command.sh (exists)
4+ skipped spec/tmp/src/upload_command.sh (exists)
5+ warning not upgrading spec/tmp/src/lib/colors.sh, unknown library 'no-such-lib'
6+ updated spec/tmp/src/lib/config.sh
7+ updated spec/tmp/src/lib/send_completions.sh
8+ updated spec/tmp/src/lib/validations/validate_dir_exists.sh
9+ updated spec/tmp/src/lib/validations/validate_file_exists.sh
10+ updated spec/tmp/src/lib/validations/validate_integer.sh
11+ updated spec/tmp/src/lib/validations/validate_not_empty.sh
12+ updated spec/tmp/src/lib/yaml.sh
13+ created spec/tmp/cli
14+ run spec/tmp/cli --help to test your bash script
Load Diff This file was deleted.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change 145145 end
146146 end
147147
148+ context "when the upgrade candidate has magic comment with an unknown library" do
149+ let ( :file ) { lib_files [ 0 ] }
150+ let ( :patched_content ) { file_content . gsub "[@bashly-upgrade colors]" , "[@bashly-upgrade no-such-lib]" }
151+ let ( :file_content ) { File . read file }
152+
153+ before do
154+ File . write file , patched_content
155+ end
156+
157+ it "shows a warning" do
158+ expect { subject . run %w[ generate -u ] } . to output_approval ( 'cli/generate/upgrade-unknown-lib' )
159+ end
160+ end
161+
148162 end
149163end
You can’t perform that action at this time.
0 commit comments