Sha256: 6d1218a18d128c3cb05fd0b16aa38d7f4d258e8d3d1db97f8b9d42a3be43f16b
Contents?: true
Size: 504 Bytes
Versions: 8
Compression:
Stored size: 504 Bytes
Contents
require "open3" RSpec.describe "ARGV-check" do it 'given 2, return 4' do workshop = "#{ENV['HOME']}/.ruby_learner/workshop" stdout, stderr, status = Open3.capture3("ruby #{workshop}/lib/workplace.rb 2") expect { puts stdout }.to output("4\n").to_stdout end it 'given 4, return 5' do workshop = "#{ENV['HOME']}/.ruby_learner/workshop" stdout, stderr, status = Open3.capture3("ruby #{workshop}/lib/workplace.rb 4") expect { puts stdout }.to output("5\n").to_stdout end end
Version data entries
8 entries across 8 versions & 1 rubygems