Module: Cucumber

Defined in:
lib/gems/cucumber-0.1.15/lib/cucumber/version.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/cli.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/tree.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/executor.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/platform.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/rake/task.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/tree/step.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/tree/table.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/broadcaster.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/model/table.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/rails/world.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/step_mother.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/step_methods.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/tree/feature.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/core_ext/proc.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/tree/features.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/tree/scenario.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/world/pending.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/tree/given_scenario.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/formatters/ansicolor.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/tree/top_down_visitor.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/formatters/html_formatter.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_ar.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_cy.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_da.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_de.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_en.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_es.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_et.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_fr.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_id.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_it.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_ja.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_ko.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_lt.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_nl.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_no.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_pl.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_pt.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_ro.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_ru.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_se.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_ro2.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/formatters/pretty_formatter.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/formatters/profile_formatter.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_en-tx.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_zh-CN.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/formatters/autotest_formatter.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/formatters/progress_formatter.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_en-lol.rb,
lib/gems/cucumber-0.1.15/lib/cucumber/treetop_parser/feature_parser.rb

Overview

:nodoc:

Defined Under Namespace

Modules: CoreExt, Formatters, Model, Rails, Rake, StepMethods, Tree, TreetopParser, World Classes: ArityMismatchError, Broadcaster, CLI, Duplicate, Executor, ForcedPending, MissingProc, Multiple, Pending, StepMother, VERSION, YmlLoadError

Constant Summary collapse

LANGUAGE_FILE =
File.expand_path(File.dirname(__FILE__) + '/languages.yml')
BINARY =
File.expand_path(File.dirname(__FILE__) + '/../../bin/cucumber')
JRUBY =
defined?(JRUBY_VERSION)
IRONRUBY =
Config::CONFIG['sitedir'] =~ /IronRuby/
WINDOWS =
Config::CONFIG['host_os'] =~ /mswin|mingw/
WINDOWS_MRI =
WINDOWS && !JRUBY && !IRONRUBY
RAILS =
defined?(Rails)
RUBY_BINARY =
File.join(Config::CONFIG['bindir'], Config::CONFIG['ruby_install_name'])
RUBY_1_9 =
RUBY_VERSION =~ /^1\.9/
CODEPAGE =
"cp#{codepage}"

Class Attribute Summary collapse

Class Method Summary collapse

Class Attribute Details

.languageObject (readonly)

Returns the value of attribute language.



17
18
19
# File 'lib/gems/cucumber-0.1.15/lib/cucumber/platform.rb', line 17

def language
  @language
end

Class Method Details

.configObject



27
28
29
30
# File 'lib/gems/cucumber-0.1.15/lib/cucumber/platform.rb', line 27

def config
  require 'yaml'
  @config ||= YAML.load_file(LANGUAGE_FILE)
end

.languagesObject



23
24
25
# File 'lib/gems/cucumber-0.1.15/lib/cucumber/platform.rb', line 23

def languages
  config.keys.sort
end

.load_language(lang) ⇒ Object



19
20
21
# File 'lib/gems/cucumber-0.1.15/lib/cucumber/platform.rb', line 19

def load_language(lang)
  @language = config[lang]
end