Fix incorrect definition of field label getter in FFI.

This was unintentionally disabling a test in repeated_field_test that is broken in JRuby FFI.  It appears to be a bug in Enumeration, rather than our code.

PiperOrigin-RevId: 616164907
pull/16192/head
Mike Kruskal 11 months ago committed by Copybara-Service
parent c17b102148
commit 4afc2cc17a
  1. 2
      ruby/lib/google/protobuf/ffi/field_descriptor.rb
  2. 1
      ruby/tests/repeated_field_test.rb

@ -68,7 +68,7 @@ module Google
end
def label
@label ||= Google::Protobuf::FFI::Label[Google::Protobuf::FFI.get_label(self)]
@label ||= Google::Protobuf::FFI.get_label(self)
end
def default

@ -37,7 +37,6 @@ class RepeatedFieldTest < Test::Unit::TestCase
repeated_field_names(TestMessage).each do |field_name|
assert_nil m.send(field_name).first
assert_empty m.send(field_name).first(0)
assert_empty m.send(field_name).first(1)
end
fill_test_msg(m)

Loading…
Cancel
Save