Sha256: 113fc6591dd606c327ee064379131776e2697a1f18e9f70ca078529fb0857e79

Contents?: true

Size: 875 Bytes

Versions: 6

Compression:

Stored size: 875 Bytes

Contents

# Shared examples for Shoes::App and Shoes::Slot (flow and stack).
# If DSL methods can be called with multiple number of arguments,
# and if they set certain defaults, then that what needs to be tested
# here.
# There are individual specs for the different Shoes elements, so
# we don't need to test how they work in details. Here we just test that
# the DSL methods construct elements correctly.
shared_examples "DSL container" do
  let(:dsl) { app }

  %w[
    animate
    arc
    background
    button
    border
    cap
    check
    edit_box
    edit_line
    fill
    flow
    gradient
    image
    line
    nofill
    nostroke
    oval
    pattern
    progress
    rect
    rgb
    shape
    star
    stroke
    strokewidth
    style
    video
  ].each do |method|
    include_examples "#{method} DSL method"
  end

  include_examples "text element DSL methods"
end

Version data entries

6 entries across 6 versions & 3 rubygems

Version Path
shoes-core-4.0.0.pre6 spec/shoes/shared_examples/dsl.rb
shoes-core-4.0.0.pre5 spec/shoes/shared_examples/dsl.rb
shoes-core-4.0.0.pre4 spec/shoes/shared_examples/dsl.rb
shoes-core-4.0.0.pre3 spec/shoes/shared_examples/dsl.rb
shoes-swt-4.0.0.pre2 spec/shoes/shared_examples/dsl.rb
shoes-dsl-4.0.0.pre2 spec/shoes/shared_examples/dsl.rb