spec/osx/symbol_constants_spec.rb in sugarcube-2.0.1 vs spec/osx/symbol_constants_spec.rb in sugarcube-2.0.2

- old
+ new

@@ -86,10 +86,27 @@ :default.nsfocusringtype.should == NSFocusRingTypeDefault :none.nsfocusringtype.should == NSFocusRingTypeNone :exterior.nsfocusringtype.should == NSFocusRingTypeExterior end + it 'should support `nslinebreakmode`' do + :word_wrapping.nslinebreakmode.should == NSLineBreakByWordWrapping + :word_wrap.nslinebreakmode.should == NSLineBreakByWordWrapping + :word.nslinebreakmode.should == NSLineBreakByWordWrapping + :char_wrapping.nslinebreakmode.should == NSLineBreakByCharWrapping + :char_wrap.nslinebreakmode.should == NSLineBreakByCharWrapping + :char.nslinebreakmode.should == NSLineBreakByCharWrapping + :clipping.nslinebreakmode.should == NSLineBreakByClipping + :clip.nslinebreakmode.should == NSLineBreakByClipping + :truncating_head.nslinebreakmode.should == NSLineBreakByTruncatingHead + :head.nslinebreakmode.should == NSLineBreakByTruncatingHead + :truncating_tail.nslinebreakmode.should == NSLineBreakByTruncatingTail + :tail.nslinebreakmode.should == NSLineBreakByTruncatingTail + :truncating_middle.nslinebreakmode.should == NSLineBreakByTruncatingMiddle + :middle.nslinebreakmode.should == NSLineBreakByTruncatingMiddle + end + it 'should support `catimingfunction`' do :linear.catimingfunction.should == KCAMediaTimingFunctionLinear :ease_in.catimingfunction.should == KCAMediaTimingFunctionEaseIn :ease_out.catimingfunction.should == KCAMediaTimingFunctionEaseOut :ease_in_out.catimingfunction.should == KCAMediaTimingFunctionEaseInEaseOut @@ -138,10 +155,14 @@ it 'should have alias for `cglinejoin`' do :miter.cglinejoinstyle.should == :miter.cglinejoin end + it 'should have alias for `nslinebreakmode`' do + :head.nslinebreakmode.should == :head.nslinebreak + end + end describe "not found" do it 'should not find nonexistant `nsautoresizingmask`' do should.raise(SugarCubeNotFoundException) { :definitely_doesnt_exist_i_am_really_sure_of_it.nsautoresizingmask } @@ -167,9 +188,13 @@ should.raise(SugarCubeNotFoundException) { :definitely_doesnt_exist_i_am_really_sure_of_it.nsbezelstyle } end it 'should not find nonexistant `nsfocusringtype`' do should.raise(SugarCubeNotFoundException) { :definitely_doesnt_exist_i_am_really_sure_of_it.nsfocusringtype } + end + + it 'should not find nonexistant `nslinebreakmode`' do + should.raise(SugarCubeNotFoundException) { :definitely_doesnt_exist_i_am_really_sure_of_it.nslinebreakmode } end it 'should not find nonexistant `catimingfunction`' do should.raise(SugarCubeNotFoundException) { :definitely_doesnt_exist_i_am_really_sure_of_it.catimingfunction } end