Sha256: 7e988f1a43fe3bdb74d018a224bb0364adac57ea9253815a9155aa4f0b3f0a5c

Contents?: true

Size: 407 Bytes

Versions: 8

Compression:

Stored size: 407 Bytes

Contents

require File.expand_path('../gir_ffi_test_helper.rb', File.dirname(__FILE__))

describe GirFFI::Builder::Type::Union do
  describe "#pretty_print" do
    it "returns a class block" do
      mock(info = Object.new).safe_name { "Bar" }
      stub(info).namespace { "Foo" }

      builder = GirFFI::Builder::Type::Union.new(info)

      assert_equal "class Bar\nend", builder.pretty_print
    end
  end
end



Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
gir_ffi-0.4.0 test/unit/union_builder_test.rb
gir_ffi-0.3.2 test/unit/union_builder_test.rb
gir_ffi-0.3.1 test/unit/union_builder_test.rb
gir_ffi-0.3.0 test/unit/union_builder_test.rb
gir_ffi-0.2.3 test/unit/union_builder_test.rb
gir_ffi-0.2.2 test/unit/union_builder_test.rb
gir_ffi-0.2.1 test/unit/union_builder_test.rb
gir_ffi-0.2.0 test/unit/union_builder_test.rb