Implement `layout' run control keyword

Allow configuration of the layout by specifying either a class or an
instance.
This commit is contained in:
Thibault Jouan
2015-04-26 00:59:24 +00:00
parent 7c06b52664
commit bf6f08e848
5 changed files with 69 additions and 10 deletions

View File

@@ -0,0 +1,27 @@
Feature: `layout' run control keyword
Background:
Given a file named my_layout.rb with:
"""
class MyLayout
def register *_
puts "testing_rc_layout"
end
end
"""
Scenario: configures a layout class
Given a run control file with:
"""
layout MyLayout
"""
When I run uhwm with options -r./my_layout
Then the output must contain "testing_rc_layout"
Scenario: configures a layout instance
Given a run control file with:
"""
layout MyLayout.new
"""
When I run uhwm with options -r./my_layout
Then the output must contain "testing_rc_layout"