Sha256: 24c3e66fe822597ffb4b361595464c205e5fb89663f4f7b544b3602dffc7ff54

Contents?: true

Size: 630 Bytes

Versions: 4

Compression:

Stored size: 630 Bytes

Contents

RSpec.describe "`<%= "#{app_name_underscored} #{cmd_name_underscored}" %>` command", type: :cli do
  it "executes `<%= "#{app_name_underscored} help #{cmd_name_underscored}" %>` command successfully" do
    output = `<%= "#{app_name_underscored} help #{cmd_name_underscored}" %>`
    expected_output = <<-OUT
    <%- if subcmd_name_underscored.to_s.empty? -%>
Usage:
  <%= app_name_underscored + ' ' + cmd_name_underscored + cmd_desc_args %>

Options:
  -h, [--help], [--no-help]  # Display usage information

<%= cmd_desc %>
    <%- else -%>
Commands:
    <%- end -%>
    OUT

    expect(output).to eq(expected_output)
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
tty-0.10.0 lib/tty/templates/add/spec/integration/command_spec.rb.tt
tty-0.9.1 lib/tty/templates/add/spec/integration/command_spec.rb.tt
tty-0.8.1 lib/tty/templates/add/spec/integration/command_spec.rb.tt
tty-0.8.0 lib/tty/templates/add/spec/integration/command_spec.rb.tt