Skip to content

Commit 0e9e9de

Browse files
committed
[rb] fix linting of tests
1 parent 0acb52e commit 0e9e9de

File tree

1 file changed

+8
-10
lines changed

1 file changed

+8
-10
lines changed

rb/spec/unit/selenium/webdriver/common/print_options_spec.rb

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -17,42 +17,40 @@
1717
# specific language governing permissions and limitations
1818
# under the License.
1919

20-
2120
require File.expand_path('../spec_helper', __dir__)
2221
require 'selenium/webdriver/common/print_options'
2322

24-
2523
module Selenium
2624
module WebDriver
2725
describe PrintOptions do
28-
let(:options) { PrintOptions.new }
26+
let(:options) { described_class.new }
2927

3028
it 'has default values' do
3129
expect(options.orientation).to eq('portrait')
3230
expect(options.scale).to eq(1.0)
3331
expect(options.background).to be(false)
34-
expect(options.page_size).to eq({ width: 21.0, height: 29.7 })
35-
expect(options.margins).to eq({ top: 1.0, bottom: 1.0, left: 1.0, right: 1.0 })
32+
expect(options.page_size).to eq({width: 21.0, height: 29.7})
33+
expect(options.margins).to eq({top: 1.0, bottom: 1.0, left: 1.0, right: 1.0})
3634
end
3735

3836
it 'can set custom page size' do
39-
custom_size = { width: 25.0, height: 30.0 }
37+
custom_size = {width: 25.0, height: 30.0}
4038
options.page_size = custom_size
4139
expect(options.page_size).to eq(custom_size)
4240
end
4341

4442
it 'can set predefined page sizes using symbols' do
4543
options.page_size = :a4
46-
expect(options.page_size).to eq({ width: 21.0, height: 29.7 })
44+
expect(options.page_size).to eq({width: 21.0, height: 29.7})
4745

4846
options.page_size = :legal
49-
expect(options.page_size).to eq({ width: 21.59, height: 35.56 })
47+
expect(options.page_size).to eq({width: 21.59, height: 35.56})
5048

5149
options.page_size = :tabloid
52-
expect(options.page_size).to eq({ width: 27.94, height: 43.18 })
50+
expect(options.page_size).to eq({width: 27.94, height: 43.18})
5351

5452
options.page_size = :letter
55-
expect(options.page_size).to eq({ width: 21.59, height: 27.94 })
53+
expect(options.page_size).to eq({width: 21.59, height: 27.94})
5654
end
5755

5856
it 'raises an error for unsupported predefined page size symbols' do

0 commit comments

Comments
 (0)