Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

2 more tests for textbuffer.

textiter->forward_find_char
textiter->backward_find_char
These both involve GI_TYPE_TAG_UNICHAR.
They fail with Glib::Object::Introspection 0.015.
  • Loading branch information...
commit 101fba260d99e3ef1270278e3fa332de2957be24 1 parent 5e8f6b9
@zpmorgan authored
Showing with 16 additions and 1 deletion.
  1. +16 −1 t/zz-GtkTextBuffer.t
View
17 t/zz-GtkTextBuffer.t
@@ -9,7 +9,7 @@ use warnings;
use utf8;
use Glib qw/TRUE FALSE/;
-plan tests => 40;
+plan tests => 42;
my $table = Gtk3::TextTagTable -> new();
@@ -158,3 +158,18 @@ $buffer -> end_user_action();
my $mark = Gtk3::TextMark -> new('bla', TRUE);
$buffer -> add_mark($mark, $end->());
}
+
+{
+ # test forward_find_char
+ # fails on Glib::Object::Introspection 0.015 with the following:
+ # "Unhandled info tag 21 in raw_to_arg"
+ use utf8;
+ my $buf = Gtk3::TextBuffer -> new();
+ $buf->set_text('v年x最y');
+ my ($s,$e) = $buf->get_bounds;
+ $s->forward_find_char( sub{shift eq ''} );
+ is($s->get_char, '');
+ $e->backward_find_char( sub{shift eq '%'},undef, $s);
+ is($e->get_char, '');
+}
+
Please sign in to comment.
Something went wrong with that request. Please try again.