Class: AllureCucumber::CucumberConfig

Inherits:
Object
  • Object
show all
Includes:
Singleton
Defined in:
lib/allure_cucumber/config.rb

Overview

Allure Cucumber configuration class

Constant Summary collapse

DEFAULT_TMS_PREFIX =

Returns default tms tag prefix.

Returns:

  • (String)

    default tms tag prefix

"TMS:"
DEFAULT_ISSUE_PREFIX =

Returns default issue tag prefix.

Returns:

  • (String)

    default issue tag prefix

"ISSUE:"
DEFAULT_SEVERITY_PREFIX =

Returns default severity tag prefix.

Returns:

  • (String)

    default severity tag prefix

"SEVERITY:"
DEFAULT_EPIC_PREFIX =

Returns default epic tag prefix.

Returns:

  • (String)

    default epic tag prefix

"EPIC:"
DEFAULT_FEATURE_PREFIX =

Returns default feature tag prefix.

Returns:

  • (String)

    default feature tag prefix

"FEATURE:"
DEFAULT_STORY_PREFIX =

Returns default story tag prefix.

Returns:

  • (String)

    default story tag prefix

"STORY:"

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeCucumberConfig

Returns a new instance of CucumberConfig.



45
46
47
# File 'lib/allure_cucumber/config.rb', line 45

def initialize
  @allure_config = Allure.configuration
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(method) ⇒ Object



79
80
81
# File 'lib/allure_cucumber/config.rb', line 79

def method_missing(method, ...)
  @allure_config.respond_to?(method) ? @allure_config.send(method, ...) : super
end

Instance Attribute Details

#clean_results_directoryBoolean

Returns:

  • (Boolean)


22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
# File 'lib/allure_cucumber/config.rb', line 22

class CucumberConfig
  include Singleton

  # @return [String] default tms tag prefix
  DEFAULT_TMS_PREFIX = "TMS:"
  # @return [String] default issue tag prefix
  DEFAULT_ISSUE_PREFIX = "ISSUE:"
  # @return [String] default severity tag prefix
  DEFAULT_SEVERITY_PREFIX = "SEVERITY:"
  # @return [String] default epic tag prefix
  DEFAULT_EPIC_PREFIX = "EPIC:"
  # @return [String] default feature tag prefix
  DEFAULT_FEATURE_PREFIX = "FEATURE:"
  # @return [String] default story tag prefix
  DEFAULT_STORY_PREFIX = "STORY:"

  attr_writer :tms_prefix,
              :issue_prefix,
              :severity_prefix,
              :epic_prefix,
              :feature_prefix,
              :story_prefix

  def initialize
    @allure_config = Allure.configuration
  end

  # @return [String]
  def tms_prefix
    @tms_prefix || DEFAULT_TMS_PREFIX
  end

  # @return [String]
  def issue_prefix
    @issue_prefix || DEFAULT_ISSUE_PREFIX
  end

  # @return [String]
  def severity_prefix
    @severity_prefix || DEFAULT_SEVERITY_PREFIX
  end

  # @return [String]
  def epic_prefix
    @epic_prefix || DEFAULT_EPIC_PREFIX
  end

  # @return [String]
  def feature_prefix
    @feature_prefix || DEFAULT_FEATURE_PREFIX
  end

  # @return [String]
  def story_prefix
    @story_prefix || DEFAULT_STORY_PREFIX
  end

  def method_missing(method, ...)
    @allure_config.respond_to?(method) ? @allure_config.send(method, ...) : super
  end

  def respond_to_missing?(method, include_private = false)
    @allure_config.respond_to?(method, include_private) || super
  end
end

#environmentString

Returns:

  • (String)


22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
# File 'lib/allure_cucumber/config.rb', line 22

class CucumberConfig
  include Singleton

  # @return [String] default tms tag prefix
  DEFAULT_TMS_PREFIX = "TMS:"
  # @return [String] default issue tag prefix
  DEFAULT_ISSUE_PREFIX = "ISSUE:"
  # @return [String] default severity tag prefix
  DEFAULT_SEVERITY_PREFIX = "SEVERITY:"
  # @return [String] default epic tag prefix
  DEFAULT_EPIC_PREFIX = "EPIC:"
  # @return [String] default feature tag prefix
  DEFAULT_FEATURE_PREFIX = "FEATURE:"
  # @return [String] default story tag prefix
  DEFAULT_STORY_PREFIX = "STORY:"

  attr_writer :tms_prefix,
              :issue_prefix,
              :severity_prefix,
              :epic_prefix,
              :feature_prefix,
              :story_prefix

  def initialize
    @allure_config = Allure.configuration
  end

  # @return [String]
  def tms_prefix
    @tms_prefix || DEFAULT_TMS_PREFIX
  end

  # @return [String]
  def issue_prefix
    @issue_prefix || DEFAULT_ISSUE_PREFIX
  end

  # @return [String]
  def severity_prefix
    @severity_prefix || DEFAULT_SEVERITY_PREFIX
  end

  # @return [String]
  def epic_prefix
    @epic_prefix || DEFAULT_EPIC_PREFIX
  end

  # @return [String]
  def feature_prefix
    @feature_prefix || DEFAULT_FEATURE_PREFIX
  end

  # @return [String]
  def story_prefix
    @story_prefix || DEFAULT_STORY_PREFIX
  end

  def method_missing(method, ...)
    @allure_config.respond_to?(method) ? @allure_config.send(method, ...) : super
  end

  def respond_to_missing?(method, include_private = false)
    @allure_config.respond_to?(method, include_private) || super
  end
end

#epic_prefixString

Returns:

  • (String)


65
66
67
# File 'lib/allure_cucumber/config.rb', line 65

def epic_prefix
  @epic_prefix || DEFAULT_EPIC_PREFIX
end

#feature_prefixString

Returns:

  • (String)


70
71
72
# File 'lib/allure_cucumber/config.rb', line 70

def feature_prefix
  @feature_prefix || DEFAULT_FEATURE_PREFIX
end

#issue_prefixString

Returns:

  • (String)


55
56
57
# File 'lib/allure_cucumber/config.rb', line 55

def issue_prefix
  @issue_prefix || DEFAULT_ISSUE_PREFIX
end

Returns:

  • (String)


22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
# File 'lib/allure_cucumber/config.rb', line 22

class CucumberConfig
  include Singleton

  # @return [String] default tms tag prefix
  DEFAULT_TMS_PREFIX = "TMS:"
  # @return [String] default issue tag prefix
  DEFAULT_ISSUE_PREFIX = "ISSUE:"
  # @return [String] default severity tag prefix
  DEFAULT_SEVERITY_PREFIX = "SEVERITY:"
  # @return [String] default epic tag prefix
  DEFAULT_EPIC_PREFIX = "EPIC:"
  # @return [String] default feature tag prefix
  DEFAULT_FEATURE_PREFIX = "FEATURE:"
  # @return [String] default story tag prefix
  DEFAULT_STORY_PREFIX = "STORY:"

  attr_writer :tms_prefix,
              :issue_prefix,
              :severity_prefix,
              :epic_prefix,
              :feature_prefix,
              :story_prefix

  def initialize
    @allure_config = Allure.configuration
  end

  # @return [String]
  def tms_prefix
    @tms_prefix || DEFAULT_TMS_PREFIX
  end

  # @return [String]
  def issue_prefix
    @issue_prefix || DEFAULT_ISSUE_PREFIX
  end

  # @return [String]
  def severity_prefix
    @severity_prefix || DEFAULT_SEVERITY_PREFIX
  end

  # @return [String]
  def epic_prefix
    @epic_prefix || DEFAULT_EPIC_PREFIX
  end

  # @return [String]
  def feature_prefix
    @feature_prefix || DEFAULT_FEATURE_PREFIX
  end

  # @return [String]
  def story_prefix
    @story_prefix || DEFAULT_STORY_PREFIX
  end

  def method_missing(method, ...)
    @allure_config.respond_to?(method) ? @allure_config.send(method, ...) : super
  end

  def respond_to_missing?(method, include_private = false)
    @allure_config.respond_to?(method, include_private) || super
  end
end

Returns:

  • (String)


22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
# File 'lib/allure_cucumber/config.rb', line 22

class CucumberConfig
  include Singleton

  # @return [String] default tms tag prefix
  DEFAULT_TMS_PREFIX = "TMS:"
  # @return [String] default issue tag prefix
  DEFAULT_ISSUE_PREFIX = "ISSUE:"
  # @return [String] default severity tag prefix
  DEFAULT_SEVERITY_PREFIX = "SEVERITY:"
  # @return [String] default epic tag prefix
  DEFAULT_EPIC_PREFIX = "EPIC:"
  # @return [String] default feature tag prefix
  DEFAULT_FEATURE_PREFIX = "FEATURE:"
  # @return [String] default story tag prefix
  DEFAULT_STORY_PREFIX = "STORY:"

  attr_writer :tms_prefix,
              :issue_prefix,
              :severity_prefix,
              :epic_prefix,
              :feature_prefix,
              :story_prefix

  def initialize
    @allure_config = Allure.configuration
  end

  # @return [String]
  def tms_prefix
    @tms_prefix || DEFAULT_TMS_PREFIX
  end

  # @return [String]
  def issue_prefix
    @issue_prefix || DEFAULT_ISSUE_PREFIX
  end

  # @return [String]
  def severity_prefix
    @severity_prefix || DEFAULT_SEVERITY_PREFIX
  end

  # @return [String]
  def epic_prefix
    @epic_prefix || DEFAULT_EPIC_PREFIX
  end

  # @return [String]
  def feature_prefix
    @feature_prefix || DEFAULT_FEATURE_PREFIX
  end

  # @return [String]
  def story_prefix
    @story_prefix || DEFAULT_STORY_PREFIX
  end

  def method_missing(method, ...)
    @allure_config.respond_to?(method) ? @allure_config.send(method, ...) : super
  end

  def respond_to_missing?(method, include_private = false)
    @allure_config.respond_to?(method, include_private) || super
  end
end

#loggerLogger (readonly)

Returns:

  • (Logger)


22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
# File 'lib/allure_cucumber/config.rb', line 22

class CucumberConfig
  include Singleton

  # @return [String] default tms tag prefix
  DEFAULT_TMS_PREFIX = "TMS:"
  # @return [String] default issue tag prefix
  DEFAULT_ISSUE_PREFIX = "ISSUE:"
  # @return [String] default severity tag prefix
  DEFAULT_SEVERITY_PREFIX = "SEVERITY:"
  # @return [String] default epic tag prefix
  DEFAULT_EPIC_PREFIX = "EPIC:"
  # @return [String] default feature tag prefix
  DEFAULT_FEATURE_PREFIX = "FEATURE:"
  # @return [String] default story tag prefix
  DEFAULT_STORY_PREFIX = "STORY:"

  attr_writer :tms_prefix,
              :issue_prefix,
              :severity_prefix,
              :epic_prefix,
              :feature_prefix,
              :story_prefix

  def initialize
    @allure_config = Allure.configuration
  end

  # @return [String]
  def tms_prefix
    @tms_prefix || DEFAULT_TMS_PREFIX
  end

  # @return [String]
  def issue_prefix
    @issue_prefix || DEFAULT_ISSUE_PREFIX
  end

  # @return [String]
  def severity_prefix
    @severity_prefix || DEFAULT_SEVERITY_PREFIX
  end

  # @return [String]
  def epic_prefix
    @epic_prefix || DEFAULT_EPIC_PREFIX
  end

  # @return [String]
  def feature_prefix
    @feature_prefix || DEFAULT_FEATURE_PREFIX
  end

  # @return [String]
  def story_prefix
    @story_prefix || DEFAULT_STORY_PREFIX
  end

  def method_missing(method, ...)
    @allure_config.respond_to?(method) ? @allure_config.send(method, ...) : super
  end

  def respond_to_missing?(method, include_private = false)
    @allure_config.respond_to?(method, include_private) || super
  end
end

#logging_levelInteger

Returns:

  • (Integer)


22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
# File 'lib/allure_cucumber/config.rb', line 22

class CucumberConfig
  include Singleton

  # @return [String] default tms tag prefix
  DEFAULT_TMS_PREFIX = "TMS:"
  # @return [String] default issue tag prefix
  DEFAULT_ISSUE_PREFIX = "ISSUE:"
  # @return [String] default severity tag prefix
  DEFAULT_SEVERITY_PREFIX = "SEVERITY:"
  # @return [String] default epic tag prefix
  DEFAULT_EPIC_PREFIX = "EPIC:"
  # @return [String] default feature tag prefix
  DEFAULT_FEATURE_PREFIX = "FEATURE:"
  # @return [String] default story tag prefix
  DEFAULT_STORY_PREFIX = "STORY:"

  attr_writer :tms_prefix,
              :issue_prefix,
              :severity_prefix,
              :epic_prefix,
              :feature_prefix,
              :story_prefix

  def initialize
    @allure_config = Allure.configuration
  end

  # @return [String]
  def tms_prefix
    @tms_prefix || DEFAULT_TMS_PREFIX
  end

  # @return [String]
  def issue_prefix
    @issue_prefix || DEFAULT_ISSUE_PREFIX
  end

  # @return [String]
  def severity_prefix
    @severity_prefix || DEFAULT_SEVERITY_PREFIX
  end

  # @return [String]
  def epic_prefix
    @epic_prefix || DEFAULT_EPIC_PREFIX
  end

  # @return [String]
  def feature_prefix
    @feature_prefix || DEFAULT_FEATURE_PREFIX
  end

  # @return [String]
  def story_prefix
    @story_prefix || DEFAULT_STORY_PREFIX
  end

  def method_missing(method, ...)
    @allure_config.respond_to?(method) ? @allure_config.send(method, ...) : super
  end

  def respond_to_missing?(method, include_private = false)
    @allure_config.respond_to?(method, include_private) || super
  end
end

#results_directoryString

Returns:

  • (String)


22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
# File 'lib/allure_cucumber/config.rb', line 22

class CucumberConfig
  include Singleton

  # @return [String] default tms tag prefix
  DEFAULT_TMS_PREFIX = "TMS:"
  # @return [String] default issue tag prefix
  DEFAULT_ISSUE_PREFIX = "ISSUE:"
  # @return [String] default severity tag prefix
  DEFAULT_SEVERITY_PREFIX = "SEVERITY:"
  # @return [String] default epic tag prefix
  DEFAULT_EPIC_PREFIX = "EPIC:"
  # @return [String] default feature tag prefix
  DEFAULT_FEATURE_PREFIX = "FEATURE:"
  # @return [String] default story tag prefix
  DEFAULT_STORY_PREFIX = "STORY:"

  attr_writer :tms_prefix,
              :issue_prefix,
              :severity_prefix,
              :epic_prefix,
              :feature_prefix,
              :story_prefix

  def initialize
    @allure_config = Allure.configuration
  end

  # @return [String]
  def tms_prefix
    @tms_prefix || DEFAULT_TMS_PREFIX
  end

  # @return [String]
  def issue_prefix
    @issue_prefix || DEFAULT_ISSUE_PREFIX
  end

  # @return [String]
  def severity_prefix
    @severity_prefix || DEFAULT_SEVERITY_PREFIX
  end

  # @return [String]
  def epic_prefix
    @epic_prefix || DEFAULT_EPIC_PREFIX
  end

  # @return [String]
  def feature_prefix
    @feature_prefix || DEFAULT_FEATURE_PREFIX
  end

  # @return [String]
  def story_prefix
    @story_prefix || DEFAULT_STORY_PREFIX
  end

  def method_missing(method, ...)
    @allure_config.respond_to?(method) ? @allure_config.send(method, ...) : super
  end

  def respond_to_missing?(method, include_private = false)
    @allure_config.respond_to?(method, include_private) || super
  end
end

#severity_prefixString

Returns:

  • (String)


60
61
62
# File 'lib/allure_cucumber/config.rb', line 60

def severity_prefix
  @severity_prefix || DEFAULT_SEVERITY_PREFIX
end

#story_prefixString

Returns:

  • (String)


75
76
77
# File 'lib/allure_cucumber/config.rb', line 75

def story_prefix
  @story_prefix || DEFAULT_STORY_PREFIX
end

#tms_prefixString

Returns:

  • (String)


50
51
52
# File 'lib/allure_cucumber/config.rb', line 50

def tms_prefix
  @tms_prefix || DEFAULT_TMS_PREFIX
end

Instance Method Details

#respond_to_missing?(method, include_private = false) ⇒ Boolean

Returns:

  • (Boolean)


83
84
85
# File 'lib/allure_cucumber/config.rb', line 83

def respond_to_missing?(method, include_private = false)
  @allure_config.respond_to?(method, include_private) || super
end