Revision: 2712 http://trac.macosforge.org/projects/ruby/changeset/2712 Author: eloy.de.enige@gmail.com Date: 2009-10-04 14:44:14 -0700 (Sun, 04 Oct 2009) Log Message: ----------- Updated MSpec to cbaea095dabfc8ac64fe87780f3f96f0110df282 Modified Paths: -------------- MacRuby/trunk/mspec/lib/mspec/commands/mspec.rb MacRuby/trunk/mspec/spec/commands/mspec_spec.rb MacRuby/trunk/mspec/upstream Modified: MacRuby/trunk/mspec/lib/mspec/commands/mspec.rb =================================================================== --- MacRuby/trunk/mspec/lib/mspec/commands/mspec.rb 2009-10-04 20:22:02 UTC (rev 2711) +++ MacRuby/trunk/mspec/lib/mspec/commands/mspec.rb 2009-10-04 21:44:14 UTC (rev 2712) @@ -35,7 +35,7 @@ options.targets options.on("-D", "--gdb", "Run under gdb") do - config[:flags] << '--gdb' + config[:use_gdb] = true end options.on("-A", "--valgrind", "Run under valgrind") do config[:flags] << '--valgrind' @@ -149,7 +149,12 @@ if config[:multi] and config[:command] == "ci" multi_exec argv else - exec config[:target], *argv + if config[:use_gdb] + more = ["--args", config[:target]] + argv + exec "gdb", *more + else + exec config[:target], *argv + end end end end Modified: MacRuby/trunk/mspec/spec/commands/mspec_spec.rb =================================================================== --- MacRuby/trunk/mspec/spec/commands/mspec_spec.rb 2009-10-04 20:22:02 UTC (rev 2711) +++ MacRuby/trunk/mspec/spec/commands/mspec_spec.rb 2009-10-04 21:44:14 UTC (rev 2712) @@ -270,11 +270,11 @@ @script.options end - it "sets flags to --gdb" do + it "sets use_gdb to true" do ["-D", "--gdb"].each do |opt| - @config[:flags] = [] + @config[:use_gdb] = false @script.options [opt] - @config[:flags].should include("--gdb") + @config[:use_gdb].should be_true end end end Modified: MacRuby/trunk/mspec/upstream =================================================================== --- MacRuby/trunk/mspec/upstream 2009-10-04 20:22:02 UTC (rev 2711) +++ MacRuby/trunk/mspec/upstream 2009-10-04 21:44:14 UTC (rev 2712) @@ -1 +1 @@ -a719211ff32b725b9e9568cf887868849e73d796 \ No newline at end of file +cbaea095dabfc8ac64fe87780f3f96f0110df282 \ No newline at end of file