Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit 2f22431

Browse files
authored
Merge pull request #22 from learn-co/update-latter-lesson-msg
Update IO to output [Y/n] in place of [Yn]
2 parents 9c71d11 + 71323b5 commit 2f22431

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

lib/learn_open/environments/base_environment.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ def warn_if_necessary(lesson)
6060
return unless lesson.later_lesson
6161

6262
io.puts 'WARNING: You are attempting to open a lesson that is beyond your current lesson.'
63-
io.print 'Are you sure you want to continue? [Yn]: '
63+
io.print 'Are you sure you want to continue? [Y/n]: '
6464

6565
warn_response = io.gets.chomp.downcase
6666
exit if !['yes', 'y'].include?(warn_response)

spec/learn_open/opener_spec.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,7 @@
160160

161161
expect(io)
162162
.to receive(:print)
163-
.with("Are you sure you want to continue? [Yn]: ")
163+
.with("Are you sure you want to continue? [Y/n]: ")
164164

165165
expect(io)
166166
.to receive(:gets)

0 commit comments

Comments
 (0)