Sha256: b2b0a533570c5439326464f8f34fe7e8828963a63679b1470bb02215c94753b3
Contents?: true
Size: 686 Bytes
Versions: 7
Compression:
Stored size: 686 Bytes
Contents
#!/usr/bin/env ruby require_relative 'cmd-helper' # We will use set as our canonical example require_relative '../../processor/command/set' class TestBaseSubcommandMgr < Test::Unit::TestCase include UnitHelper def setup common_setup end def test_basic my_cmd = @cmds['show'] assert_equal([:debug, :different, :directories], my_cmd.complete('d'), "Should be able to complete 'd'") assert_equal(%w(show args), my_cmd.subcmds.lookup('ar').prefix, "Should be able to complete lookup('ar')") assert_equal(nil, my_cmd.subcmds.lookup('a'), "Shouldn't find since we have 'show args' and 'show auto'") end end
Version data entries
7 entries across 7 versions & 1 rubygems