spec/ffi-tk/variable.rb in ffi-tk-2010.08.23 vs spec/ffi-tk/variable.rb in ffi-tk-2018.02.20

- old
+ new

@@ -1,24 +1,25 @@ +# frozen_string_literal: true require_relative '../helper' Tk.init describe Tk::Variable do it 'creates a Variable' do @var = Tk::Variable.new('somevar') - @var.name.should == "somevar" + @var.name.should == 'somevar' end it 'cannot get a value from it yet' do - lambda{ @var.get }.should.raise(NameError) + -> { @var.get }.should.raise(NameError) end it 'sets the value and retrieves it' do @var.set('Hello, World!') @var.to_s.should == 'Hello, World!' end it 'unsets the variable' do @var.unset - lambda{ @var.get }.should.raise(NameError) + -> { @var.get }.should.raise(NameError) end -end \ No newline at end of file +end