Решение на Трета задача - Четене на командни аргументи от Христо Христов
Обратно към всички решения
Към профила на Христо Христов
Резултати
- 5 точки от тестове
- 0 бонус точки
- 5 точки общо
- 12 успешни тест(а)
- 3 неуспешни тест(а)
Код
Лог от изпълнението
.......FFF.....
Failures:
1) CommandParser#help shows basic usage message
Failure/Error: expect(parser.help).to eq 'Usage: ls'
expected: "Usage: ls"
got: "Usage: ls\n"
(compared using ==)
Diff:
# /tmp/d20161113-27983-xg8qx2/spec.rb:104:in `block (3 levels) in <top (required)>'
# ./lib/language/ruby/run_with_timeout.rb:7:in `block (3 levels) in <top (required)>'
# ./lib/language/ruby/run_with_timeout.rb:7:in `block (2 levels) in <top (required)>'
2) CommandParser#help shows single argument
Failure/Error: expect(parser.help).to eq 'Usage: ls [FILE]'
expected: "Usage: ls [FILE]"
got: "Usage: ls [FILE]\n"
(compared using ==)
Diff:
# /tmp/d20161113-27983-xg8qx2/spec.rb:110:in `block (3 levels) in <top (required)>'
# ./lib/language/ruby/run_with_timeout.rb:7:in `block (3 levels) in <top (required)>'
# ./lib/language/ruby/run_with_timeout.rb:7:in `block (2 levels) in <top (required)>'
3) CommandParser#help shows multiple arguments
Failure/Error: expect(parser.help).to eq 'Usage: ls [FIRST FILE] [SECOND FILE] [THIRD FILE]'
expected: "Usage: ls [FIRST FILE] [SECOND FILE] [THIRD FILE]"
got: "Usage: ls [FIRST FILE] [SECOND FILE] [THIRD FILE]\n"
(compared using ==)
Diff:
# /tmp/d20161113-27983-xg8qx2/spec.rb:118:in `block (3 levels) in <top (required)>'
# ./lib/language/ruby/run_with_timeout.rb:7:in `block (3 levels) in <top (required)>'
# ./lib/language/ruby/run_with_timeout.rb:7:in `block (2 levels) in <top (required)>'
Finished in 0.01056 seconds
15 examples, 3 failures
Failed examples:
rspec /tmp/d20161113-27983-xg8qx2/spec.rb:103 # CommandParser#help shows basic usage message
rspec /tmp/d20161113-27983-xg8qx2/spec.rb:107 # CommandParser#help shows single argument
rspec /tmp/d20161113-27983-xg8qx2/spec.rb:113 # CommandParser#help shows multiple arguments
История (4 версии и 0 коментара)
Христо обнови решението на 07.11.2016 14:39 (преди около 8 години)
Христо обнови решението на 08.11.2016 01:16 (преди около 8 години)
Христо обнови решението на 08.11.2016 01:18 (преди около 8 години)
Христо обнови решението на 08.11.2016 12:08 (преди около 8 години)