Sha256: 1c770098a70cbce1ff9db103e89641c9d7498ce7e2c9f6e96527bfa4d4d9a45d
Contents?: true
Size: 325 Bytes
Versions: 1
Compression:
Stored size: 325 Bytes
Contents
# frozen_string_literal: true RSpec.describe TTY::Command, 'input' do it "reads user input data" do cli = fixtures_path('cli') output = StringIO.new command = TTY::Command.new(output: output) out, _ = command.run("ruby #{cli}", input: "Piotr\n") expect(out.chomp).to eq("Your name: Piotr") end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
tty-command-0.9.0 | spec/unit/input_spec.rb |