Sha256: 4e5ebec11bfb140011b16ee3b1379692a0ea53bbc71e5ee7d39a4358ad0e0e74
Contents?: true
Size: 838 Bytes
Versions: 109
Compression:
Stored size: 838 Bytes
Contents
# encoding: utf-8 require File.expand_path(File.dirname(__FILE__) + '/../../spec_helper') require 'gherkin/formatter/argument' module Gherkin module Formatter class BracketFormat class << self def new defined?(JRUBY_VERSION) ? ::Java::GherkinFormatter::ArgumentFormat.new("[", "]") : super end end def format_argument(s) "[#{s}]" end end describe Argument do it "should replace one arg" do argument_class = defined?(JRUBY_VERSION) ? ::Java::GherkinFormatter::Argument : Argument argument_class.format("I have 10 cukes", BracketFormat.new, [Argument.new(7, '10')]).should == "I have [10] cukes" end # TODO: Add this spec: http://github.com/alg/cucumber/commit/33188e9db51f59ced74c4861524d7b2e69454630 end end end
Version data entries
109 entries across 109 versions & 1 rubygems