Sha256: cb36844d45bea04c4425e43ce106db699001e1122c5cfd45e5d6c4274c44fa28

Contents?: true

Size: 499 Bytes

Versions: 9

Compression:

Stored size: 499 Bytes

Contents

# frozen_string_literal: true

require 'gir_ffi_test_helper'

describe GirFFI::TypeMap do
  describe '.type_specification_to_ffi_type' do
    it 'returns the nested FFI::Enum for an Enum module' do
      GirFFI::TypeMap.type_specification_to_ffi_type(GLib::DateMonth).
        must_equal GLib::DateMonth
    end

    it 'returns the class itself for a Struct class' do
      GirFFI::TypeMap.type_specification_to_ffi_type(GObject::EnumValue).
        must_equal GObject::EnumValue
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
gir_ffi-0.14.1 test/gir_ffi/type_map_test.rb
gir_ffi-0.14.0 test/gir_ffi/type_map_test.rb
gir_ffi-0.13.1 test/gir_ffi/type_map_test.rb
gir_ffi-0.13.0 test/gir_ffi/type_map_test.rb
gir_ffi-0.12.1 test/gir_ffi/type_map_test.rb
gir_ffi-0.12.0 test/gir_ffi/type_map_test.rb
gir_ffi-0.11.4 test/gir_ffi/type_map_test.rb
gir_ffi-0.11.3 test/gir_ffi/type_map_test.rb
gir_ffi-0.11.2 test/gir_ffi/type_map_test.rb