gir_ffi 0.8.3 → 0.8.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (39) hide show
  1. checksums.yaml +4 -4
  2. data/Changelog.md +9 -1
  3. data/Gemfile +1 -1
  4. data/README.md +3 -2
  5. data/lib/ffi-glib/bytes.rb +0 -14
  6. data/lib/ffi-glib/hash_table.rb +0 -1
  7. data/lib/ffi-gobject/object.rb +7 -0
  8. data/lib/ffi-gobject_introspection/i_base_info.rb +4 -0
  9. data/lib/ffi-gobject_introspection/lib.rb +1 -0
  10. data/lib/gir_ffi/boxed_base.rb +2 -2
  11. data/lib/gir_ffi/builders/callback_argument_builder.rb +3 -1
  12. data/lib/gir_ffi/builders/closure_return_value_builder.rb +0 -1
  13. data/lib/gir_ffi/builders/module_builder.rb +9 -2
  14. data/lib/gir_ffi/builders/null_class_builder.rb +1 -0
  15. data/lib/gir_ffi/builders/registered_type_builder.rb +5 -1
  16. data/lib/gir_ffi/callback_base.rb +2 -2
  17. data/lib/gir_ffi/enum_base.rb +2 -2
  18. data/lib/gir_ffi/in_out_pointer.rb +1 -1
  19. data/lib/gir_ffi/info_ext/i_registered_type_info.rb +1 -1
  20. data/lib/gir_ffi/object_base.rb +24 -8
  21. data/lib/gir_ffi/sized_array.rb +2 -2
  22. data/lib/gir_ffi/version.rb +1 -1
  23. data/lib/gir_ffi/zero_terminated.rb +12 -1
  24. data/lib/gir_ffi-base/glib/boolean.rb +2 -2
  25. data/tasks/test.rake +25 -23
  26. data/test/base_test_helper.rb +3 -4
  27. data/test/ffi-gobject/object_test.rb +10 -4
  28. data/test/ffi-gobject_introspection/i_property_info_test.rb +3 -2
  29. data/test/gir_ffi/builders/module_builder_test.rb +26 -3
  30. data/test/gir_ffi/object_base_test.rb +2 -2
  31. data/test/integration/generated_everything_test.rb +428 -0
  32. data/test/integration/generated_gimarshallingtests_test.rb +17 -0
  33. data/test/integration/generated_gtop_test.rb +21 -0
  34. data/test/integration/generated_regress_test.rb +734 -0
  35. data/test/integration/generated_warnlib_test.rb +47 -0
  36. data/test/introspection_test_helper.rb +2 -0
  37. data/test/lib/Makefile.am +82 -16
  38. data/test/lib/configure.ac +3 -0
  39. metadata +5 -2
@@ -3,6 +3,16 @@ require 'gir_ffi_test_helper'
3
3
 
4
4
  GirFFI.setup :Regress
5
5
 
6
+ if IntrospectionTestExtensions.get_introspection_data 'Regress', 'TestInheritDrawable'
7
+ class ConcreteDrawable < Regress::TestInheritDrawable
8
+ def initialize
9
+ super(self.class.gtype, [])
10
+ end
11
+ end
12
+
13
+ GirFFI.define_type ConcreteDrawable
14
+ end
15
+
6
16
  # Tests generated methods and functions in the Regress namespace.
7
17
  describe Regress do
8
18
  describe Regress::Lib do
@@ -12,6 +22,19 @@ describe Regress do
12
22
  end
13
23
  end
14
24
  end
25
+ it 'has the constant ANNOTATION_CALCULATED_DEFINE' do
26
+ skip unless get_introspection_data 'Regress', 'ANNOTATION_CALCULATED_DEFINE'
27
+ Regress::ANNOTATION_CALCULATED_DEFINE.must_equal 100
28
+ end
29
+ it 'has the constant ANNOTATION_CALCULATED_LARGE' do
30
+ skip unless get_introspection_data 'Regress', 'ANNOTATION_CALCULATED_LARGE'
31
+ skip 'Constant is marked with the wrong type'
32
+ Regress::ANNOTATION_CALCULATED_LARGE.must_equal 10_000_000_000
33
+ end
34
+ it 'has the constant ANNOTATION_CALCULATED_LARGE_DIV' do
35
+ skip unless get_introspection_data 'Regress', 'ANNOTATION_CALCULATED_LARGE_DIV'
36
+ Regress::ANNOTATION_CALCULATED_LARGE_DIV.must_equal 1_000_000
37
+ end
15
38
  describe 'Regress::ATestError' do
16
39
  before do
17
40
  skip unless get_introspection_data 'Regress', 'ATestError'
@@ -30,6 +53,215 @@ describe Regress do
30
53
  end
31
54
  end
32
55
 
56
+ describe 'Regress::AnAnonymousUnion' do
57
+ before do
58
+ skip unless get_introspection_data 'Regress', 'AnAnonymousUnion'
59
+ end
60
+
61
+ let(:instance) { Regress::AnAnonymousUnion.new }
62
+
63
+ it 'has a writable field x' do
64
+ instance.x.must_equal 0
65
+ instance.x = 42
66
+ instance.x.must_equal 42
67
+ end
68
+
69
+ it 'has a writable field a' do
70
+ skip 'Not implemented yet'
71
+ end
72
+
73
+ it 'has a writable field padding' do
74
+ skip 'Not implemented yet'
75
+ end
76
+ end
77
+
78
+ describe 'Regress::AnnotationBitfield' do
79
+ before do
80
+ skip unless get_introspection_data 'Regress', 'AnnotationBitfield'
81
+ end
82
+ it 'has the member :foo' do
83
+ Regress::AnnotationBitfield[:foo].must_equal 1
84
+ end
85
+ it 'has the member :bar' do
86
+ Regress::AnnotationBitfield[:bar].must_equal 2
87
+ end
88
+ end
89
+
90
+ describe 'Regress::AnnotationFields' do
91
+ before do
92
+ skip unless get_introspection_data 'Regress', 'AnnotationFields'
93
+ end
94
+
95
+ let(:instance) { Regress::AnnotationFields.new }
96
+
97
+ it 'has a writable field field1' do
98
+ instance.field1.must_equal 0
99
+ instance.field1 = 42
100
+ instance.field1.must_equal 42
101
+ end
102
+
103
+ it 'has a writable field arr' do
104
+ instance.arr.must_equal nil
105
+ instance.arr = [1, 2, 3]
106
+ # TODO: len should be set automatically
107
+ instance.len = 3
108
+ instance.arr.to_a.must_equal [1, 2, 3]
109
+ instance.len.must_equal 3
110
+ end
111
+
112
+ it 'has a writable field len' do
113
+ skip 'len should not be set independently'
114
+ end
115
+ end
116
+
117
+ describe 'Regress::AnnotationObject' do
118
+ it 'has a working method #allow_none' do
119
+ skip 'Needs testing'
120
+ end
121
+ it 'has a working method #calleeowns' do
122
+ skip 'Needs testing'
123
+ end
124
+ it 'has a working method #calleesowns' do
125
+ skip 'Needs testing'
126
+ end
127
+ it 'has a working method #compute_sum' do
128
+ skip 'Needs testing'
129
+ end
130
+ it 'has a working method #compute_sum_n' do
131
+ skip 'Needs testing'
132
+ end
133
+ it 'has a working method #compute_sum_nz' do
134
+ skip 'Needs testing'
135
+ end
136
+ it 'has a working method #create_object' do
137
+ skip 'Needs testing'
138
+ end
139
+ it 'has a working method #do_not_use' do
140
+ skip 'Needs testing'
141
+ end
142
+ it 'has a working method #extra_annos' do
143
+ skip 'Needs testing'
144
+ end
145
+ it 'has a working method #foreach' do
146
+ skip 'Needs testing'
147
+ end
148
+ it 'has a working method #get_hash' do
149
+ skip 'Needs testing'
150
+ end
151
+ it 'has a working method #get_objects' do
152
+ skip 'Needs testing'
153
+ end
154
+ it 'has a working method #get_strings' do
155
+ skip 'Needs testing'
156
+ end
157
+ it 'has a working method #hidden_self' do
158
+ skip 'Needs testing'
159
+ end
160
+ it 'has a working method #in' do
161
+ skip 'Needs testing'
162
+ end
163
+ it 'has a working method #inout' do
164
+ skip 'Needs testing'
165
+ end
166
+ it 'has a working method #inout2' do
167
+ skip 'Needs testing'
168
+ end
169
+ it 'has a working method #inout3' do
170
+ skip 'Needs testing'
171
+ end
172
+ it 'has a working method #method' do
173
+ skip 'Needs testing'
174
+ end
175
+ it 'has a working method #notrans' do
176
+ skip 'Needs testing'
177
+ end
178
+ it 'has a working method #out' do
179
+ skip 'Needs testing'
180
+ end
181
+ it 'has a working method #parse_args' do
182
+ skip 'Needs testing'
183
+ end
184
+ it 'has a working method #set_data' do
185
+ skip 'Needs testing'
186
+ end
187
+ it 'has a working method #set_data2' do
188
+ skip 'Needs testing'
189
+ end
190
+ it 'has a working method #set_data3' do
191
+ skip 'Needs testing'
192
+ end
193
+ it 'has a working method #string_out' do
194
+ skip 'Needs testing'
195
+ end
196
+ it 'has a working method #use_buffer' do
197
+ skip 'Needs testing'
198
+ end
199
+ it 'has a working method #watch_full' do
200
+ skip 'Needs testing'
201
+ end
202
+ it 'has a working method #with_voidp' do
203
+ skip 'Needs testing'
204
+ end
205
+ describe "its 'function-property' property" do
206
+ it 'can be retrieved with #get_property' do
207
+ skip 'Needs testing'
208
+ end
209
+ it 'can be retrieved with #function_property' do
210
+ skip 'Needs testing'
211
+ end
212
+ it 'can be set with #set_property' do
213
+ skip 'Needs testing'
214
+ end
215
+ it 'can be set with #function_property=' do
216
+ skip 'Needs testing'
217
+ end
218
+ end
219
+ describe "its 'string-property' property" do
220
+ it 'can be retrieved with #get_property' do
221
+ skip 'Needs testing'
222
+ end
223
+ it 'can be retrieved with #string_property' do
224
+ skip 'Needs testing'
225
+ end
226
+ it 'can be set with #set_property' do
227
+ skip 'Needs testing'
228
+ end
229
+ it 'can be set with #string_property=' do
230
+ skip 'Needs testing'
231
+ end
232
+ end
233
+ describe "its 'tab-property' property" do
234
+ it 'can be retrieved with #get_property' do
235
+ skip 'Needs testing'
236
+ end
237
+ it 'can be retrieved with #tab_property' do
238
+ skip 'Needs testing'
239
+ end
240
+ it 'can be set with #set_property' do
241
+ skip 'Needs testing'
242
+ end
243
+ it 'can be set with #tab_property=' do
244
+ skip 'Needs testing'
245
+ end
246
+ end
247
+ it "handles the 'attribute-signal' signal" do
248
+ skip 'Needs testing'
249
+ end
250
+ it "handles the 'doc-empty-arg-parsing' signal" do
251
+ skip 'Needs testing'
252
+ end
253
+ it "handles the 'list-signal' signal" do
254
+ skip 'Needs testing'
255
+ end
256
+ it "handles the 'string-signal' signal" do
257
+ skip 'Needs testing'
258
+ end
259
+ end
260
+ describe 'Regress::AnnotationStruct' do
261
+ it 'has a writable field objects' do
262
+ skip 'Needs testing'
263
+ end
264
+ end
33
265
  it 'has the constant BOOL_CONSTANT' do
34
266
  skip unless get_introspection_data 'Regress', 'BOOL_CONSTANT'
35
267
  Regress::BOOL_CONSTANT.must_equal true
@@ -39,6 +271,356 @@ describe Regress do
39
271
  assert_equal 44.22, Regress::DOUBLE_CONSTANT
40
272
  end
41
273
 
274
+ it 'has the constant FOO_DEFINE_SHOULD_BE_EXPOSED' do
275
+ skip 'Needs testing'
276
+ end
277
+ it 'has the constant FOO_PIE_IS_TASTY' do
278
+ skip 'Needs testing'
279
+ end
280
+ it 'has the constant FOO_SUCCESS_INT' do
281
+ skip 'Needs testing'
282
+ end
283
+ describe 'Regress::FooASingle' do
284
+ it 'has the member :foo_some_single_enum' do
285
+ skip 'Needs testing'
286
+ end
287
+ end
288
+ describe 'Regress::FooAddressType' do
289
+ it 'has the member :invalid' do
290
+ skip 'Needs testing'
291
+ end
292
+ it 'has the member :ipv4' do
293
+ skip 'Needs testing'
294
+ end
295
+ it 'has the member :ipv6' do
296
+ skip 'Needs testing'
297
+ end
298
+ end
299
+ describe 'Regress::FooBRect' do
300
+ it 'has a writable field x' do
301
+ skip 'Needs testing'
302
+ end
303
+ it 'has a writable field y' do
304
+ skip 'Needs testing'
305
+ end
306
+ it 'creates an instance using #new' do
307
+ skip 'Needs testing'
308
+ end
309
+ it 'has a working method #add' do
310
+ skip 'Needs testing'
311
+ end
312
+ end
313
+ describe 'Regress::FooBUnion' do
314
+ it 'has a writable field type' do
315
+ skip 'Needs testing'
316
+ end
317
+ it 'has a writable field v' do
318
+ skip 'Needs testing'
319
+ end
320
+ it 'has a writable field rect' do
321
+ skip 'Needs testing'
322
+ end
323
+ it 'creates an instance using #new' do
324
+ skip 'Needs testing'
325
+ end
326
+ it 'has a working method #get_contained_type' do
327
+ skip 'Needs testing'
328
+ end
329
+ end
330
+ describe 'Regress::FooBoxed' do
331
+ it 'creates an instance using #new' do
332
+ skip 'Needs testing'
333
+ end
334
+ it 'has a working method #method' do
335
+ skip 'Needs testing'
336
+ end
337
+ end
338
+ describe 'Regress::FooBuffer' do
339
+ it 'has a working method #some_method' do
340
+ skip 'Needs testing'
341
+ end
342
+ end
343
+ describe 'Regress::FooDBusData' do
344
+ it 'has a working method #method' do
345
+ skip 'Needs testing'
346
+ end
347
+ end
348
+ describe 'Regress::FooEnumFullname' do
349
+ it 'has the member :one' do
350
+ skip 'Needs testing'
351
+ end
352
+ it 'has the member :two' do
353
+ skip 'Needs testing'
354
+ end
355
+ it 'has the member :three' do
356
+ skip 'Needs testing'
357
+ end
358
+ end
359
+ describe 'Regress::FooEnumNoType' do
360
+ it 'has the member :un' do
361
+ skip 'Needs testing'
362
+ end
363
+ it 'has the member :deux' do
364
+ skip 'Needs testing'
365
+ end
366
+ it 'has the member :trois' do
367
+ skip 'Needs testing'
368
+ end
369
+ it 'has the member :neuf' do
370
+ skip 'Needs testing'
371
+ end
372
+ end
373
+ describe 'Regress::FooEnumType' do
374
+ it 'has the member :alpha' do
375
+ skip 'Needs testing'
376
+ end
377
+ it 'has the member :beta' do
378
+ skip 'Needs testing'
379
+ end
380
+ it 'has the member :delta' do
381
+ skip 'Needs testing'
382
+ end
383
+ it 'has a working function #method' do
384
+ skip 'Needs testing'
385
+ end
386
+ it 'has a working function #returnv' do
387
+ skip 'Needs testing'
388
+ end
389
+ end
390
+ describe 'Regress::FooError' do
391
+ it 'has the member :good' do
392
+ skip 'Needs testing'
393
+ end
394
+ it 'has the member :bad' do
395
+ skip 'Needs testing'
396
+ end
397
+ it 'has the member :ugly' do
398
+ skip 'Needs testing'
399
+ end
400
+ it 'has a working function #quark' do
401
+ skip 'Needs testing'
402
+ end
403
+ end
404
+ describe 'Regress::FooEvent' do
405
+ it 'has a writable field type' do
406
+ skip 'Needs testing'
407
+ end
408
+ it 'has a writable field any' do
409
+ skip 'Needs testing'
410
+ end
411
+ it 'has a writable field expose' do
412
+ skip 'Needs testing'
413
+ end
414
+ end
415
+ describe 'Regress::FooEventAny' do
416
+ it 'has a writable field send_event' do
417
+ skip 'Needs testing'
418
+ end
419
+ end
420
+ describe 'Regress::FooEventExpose' do
421
+ it 'has a writable field send_event' do
422
+ skip 'Needs testing'
423
+ end
424
+ it 'has a writable field count' do
425
+ skip 'Needs testing'
426
+ end
427
+ end
428
+ describe 'Regress::FooFlagsNoType' do
429
+ it 'has the member :ett' do
430
+ skip 'Needs testing'
431
+ end
432
+ it 'has the member :tva' do
433
+ skip 'Needs testing'
434
+ end
435
+ it 'has the member :fyra' do
436
+ skip 'Needs testing'
437
+ end
438
+ end
439
+ describe 'Regress::FooFlagsType' do
440
+ it 'has the member :first' do
441
+ skip 'Needs testing'
442
+ end
443
+ it 'has the member :second' do
444
+ skip 'Needs testing'
445
+ end
446
+ it 'has the member :third' do
447
+ skip 'Needs testing'
448
+ end
449
+ end
450
+ describe 'Regress::FooForeignStruct' do
451
+ it 'has a writable field regress_foo' do
452
+ skip 'Needs testing'
453
+ end
454
+ it 'creates an instance using #new' do
455
+ skip 'Needs testing'
456
+ end
457
+ it 'has a working method #copy' do
458
+ skip 'Needs testing'
459
+ end
460
+ end
461
+ describe 'Regress::FooInterface' do
462
+ it 'has a working function #static_method' do
463
+ skip 'Needs testing'
464
+ end
465
+ it 'has a working method #do_regress_foo' do
466
+ skip 'Needs testing'
467
+ end
468
+ end
469
+ describe 'Regress::FooObject' do
470
+ it 'creates an instance using #new' do
471
+ skip 'Needs testing'
472
+ end
473
+ it 'creates an instance using #new_as_super' do
474
+ skip 'Needs testing'
475
+ end
476
+ it 'has a working function #a_global_method' do
477
+ skip 'Needs testing'
478
+ end
479
+ it 'has a working function #get_default' do
480
+ skip 'Needs testing'
481
+ end
482
+ it 'has a working function #static_meth' do
483
+ skip 'Needs testing'
484
+ end
485
+ it 'has a working method #append_new_stack_layer' do
486
+ skip 'Needs testing'
487
+ end
488
+ it 'has a working method #dup_name' do
489
+ skip 'Needs testing'
490
+ end
491
+ it 'has a working method #external_type' do
492
+ skip 'Needs testing'
493
+ end
494
+ it 'has a working method #get_name' do
495
+ skip 'Needs testing'
496
+ end
497
+ it 'has a working method #handle_glyph' do
498
+ skip 'Needs testing'
499
+ end
500
+ it 'has a working method #is_it_time_yet' do
501
+ skip 'Needs testing'
502
+ end
503
+ it 'has a working method #read' do
504
+ skip 'Needs testing'
505
+ end
506
+ it 'has a working method #various' do
507
+ skip 'Needs testing'
508
+ end
509
+ it 'has a working method #virtual_method' do
510
+ skip 'Needs testing'
511
+ end
512
+ describe "its 'string' property" do
513
+ it 'can be retrieved with #get_property' do
514
+ skip 'Needs testing'
515
+ end
516
+ it 'can be retrieved with #string' do
517
+ skip 'Needs testing'
518
+ end
519
+ it 'can be set with #set_property' do
520
+ skip 'Needs testing'
521
+ end
522
+ it 'can be set with #string=' do
523
+ skip 'Needs testing'
524
+ end
525
+ end
526
+ it "handles the 'signal' signal" do
527
+ end
528
+ end
529
+ describe 'Regress::FooOtherObject' do
530
+ end
531
+ describe 'Regress::FooRectangle' do
532
+ it 'has a writable field x' do
533
+ skip 'Needs testing'
534
+ end
535
+ it 'has a writable field y' do
536
+ skip 'Needs testing'
537
+ end
538
+ it 'has a writable field width' do
539
+ skip 'Needs testing'
540
+ end
541
+ it 'has a writable field height' do
542
+ skip 'Needs testing'
543
+ end
544
+ it 'has a working method #add' do
545
+ skip 'Needs testing'
546
+ end
547
+ end
548
+ describe 'Regress::FooStackLayer' do
549
+ it 'has the member :desktop' do
550
+ skip 'Needs testing'
551
+ end
552
+ it 'has the member :bottom' do
553
+ skip 'Needs testing'
554
+ end
555
+ it 'has the member :normal' do
556
+ skip 'Needs testing'
557
+ end
558
+ it 'has the member :top' do
559
+ skip 'Needs testing'
560
+ end
561
+ it 'has the member :dock' do
562
+ skip 'Needs testing'
563
+ end
564
+ it 'has the member :fullscreen' do
565
+ skip 'Needs testing'
566
+ end
567
+ it 'has the member :focused_window' do
568
+ skip 'Needs testing'
569
+ end
570
+ it 'has the member :override_redirect' do
571
+ skip 'Needs testing'
572
+ end
573
+ it 'has the member :last' do
574
+ skip 'Needs testing'
575
+ end
576
+ end
577
+ describe 'Regress::FooStruct' do
578
+ it 'has a writable field priv' do
579
+ skip 'Needs testing'
580
+ end
581
+ it 'has a writable field member' do
582
+ skip 'Needs testing'
583
+ end
584
+ end
585
+ describe 'Regress::FooSubInterface' do
586
+ it 'has a working method #do_bar' do
587
+ skip 'Needs testing'
588
+ end
589
+ it 'has a working method #do_baz' do
590
+ skip 'Needs testing'
591
+ end
592
+ it "handles the 'destroy-event' signal" do
593
+ end
594
+ end
595
+ describe 'Regress::FooSubobject' do
596
+ it 'creates an instance using #new' do
597
+ skip 'Needs testing'
598
+ end
599
+ end
600
+ describe 'Regress::FooThingWithArray' do
601
+ it 'has a writable field x' do
602
+ skip 'Needs testing'
603
+ end
604
+ it 'has a writable field y' do
605
+ skip 'Needs testing'
606
+ end
607
+ it 'has a writable field lines' do
608
+ skip 'Needs testing'
609
+ end
610
+ it 'has a writable field data' do
611
+ skip 'Needs testing'
612
+ end
613
+ end
614
+ describe 'Regress::FooUnion' do
615
+ it 'has a writable field regress_foo' do
616
+ skip 'Needs testing'
617
+ end
618
+ end
619
+ describe 'Regress::FooUtilityStruct' do
620
+ it 'has a writable field bar' do
621
+ skip 'Needs testing'
622
+ end
623
+ end
42
624
  it 'has the constant GI_SCANNER_ELSE' do
43
625
  skip unless get_introspection_data 'Regress', 'GI_SCANNER_ELSE'
44
626
  Regress::GI_SCANNER_ELSE.must_equal 3
@@ -507,6 +1089,37 @@ describe Regress do
507
1089
  end
508
1090
  end
509
1091
 
1092
+ describe 'Regress::TestInheritDrawable' do
1093
+ before do
1094
+ skip unless get_introspection_data 'Regress', 'TestInheritDrawable'
1095
+ end
1096
+
1097
+ let(:instance) { ConcreteDrawable.new }
1098
+ it 'has a working method #do_foo' do
1099
+ instance.do_foo 42
1100
+ pass
1101
+ end
1102
+
1103
+ it 'has a working method #do_foo_maybe_throw' do
1104
+ instance.do_foo_maybe_throw 42
1105
+ proc { instance.do_foo_maybe_throw 41 }.must_raise GirFFI::GLibError
1106
+ end
1107
+
1108
+ it 'has a working method #get_origin' do
1109
+ instance.get_origin.must_equal [0, 0]
1110
+ end
1111
+
1112
+ it 'has a working method #get_size' do
1113
+ instance.get_size.must_equal [42, 42]
1114
+ end
1115
+ end
1116
+
1117
+ describe 'Regress::TestInheritPixmapObjectClass' do
1118
+ it 'has a writable field parent_class' do
1119
+ skip 'This is a class struct without defined class'
1120
+ end
1121
+ end
1122
+
510
1123
  describe 'Regress::TestInterface' do
511
1124
  it 'is a module' do
512
1125
  assert_instance_of Module, Regress::TestInterface
@@ -1699,18 +2312,126 @@ describe Regress do
1699
2312
  result.must_be_instance_of Regress::TestBoxed
1700
2313
  end
1701
2314
 
2315
+ it 'has a working function #annotation_attribute_func' do
2316
+ skip 'Needs testing'
2317
+ end
2318
+ it 'has a working function #annotation_custom_destroy' do
2319
+ skip 'Needs testing'
2320
+ end
2321
+ it 'has a working function #annotation_get_source_file' do
2322
+ skip 'Needs testing'
2323
+ end
2324
+ it 'has a working function #annotation_init' do
2325
+ skip 'Needs testing'
2326
+ end
2327
+ it 'has a working function #annotation_invalid_regress_annotation' do
2328
+ skip 'Needs testing'
2329
+ end
2330
+ it 'has a working function #annotation_ptr_array' do
2331
+ skip 'Needs testing'
2332
+ end
2333
+ it 'has a working function #annotation_return_array' do
2334
+ skip 'Needs testing'
2335
+ end
2336
+ it 'has a working function #annotation_return_filename' do
2337
+ skip 'Needs testing'
2338
+ end
2339
+ it 'has a working function #annotation_set_source_file' do
2340
+ skip 'Needs testing'
2341
+ end
2342
+ it 'has a working function #annotation_space_after_comment_bug631690' do
2343
+ skip 'Needs testing'
2344
+ end
2345
+ it 'has a working function #annotation_string_array_length' do
2346
+ skip 'Needs testing'
2347
+ end
2348
+ it 'has a working function #annotation_string_zero_terminated' do
2349
+ skip 'Needs testing'
2350
+ end
2351
+ it 'has a working function #annotation_string_zero_terminated_out' do
2352
+ skip 'Needs testing'
2353
+ end
2354
+ it 'has a working function #annotation_test_parsing_bug630862' do
2355
+ skip 'Needs testing'
2356
+ end
2357
+ it 'has a working function #annotation_transfer_floating' do
2358
+ skip 'Needs testing'
2359
+ end
2360
+ it 'has a working function #annotation_versioned' do
2361
+ skip 'Needs testing'
2362
+ end
1702
2363
  it 'has a working function #atest_error_quark' do
1703
2364
  skip unless get_introspection_data 'Regress', 'atest_error_quark'
1704
2365
  result = Regress.atest_error_quark
1705
2366
  GLib.quark_to_string(result).must_equal 'regress-atest-error'
1706
2367
  end
1707
2368
 
2369
+ it 'has a working function #foo_async_ready_callback' do
2370
+ skip 'Needs testing'
2371
+ end
2372
+ it 'has a working function #foo_destroy_notify_callback' do
2373
+ skip 'Needs testing'
2374
+ end
2375
+ it 'has a working function #foo_enum_type_method' do
2376
+ skip 'Needs testing'
2377
+ end
2378
+ it 'has a working function #foo_enum_type_returnv' do
2379
+ skip 'Needs testing'
2380
+ end
2381
+ it 'has a working function #foo_error_quark' do
2382
+ skip 'Needs testing'
2383
+ end
2384
+ it 'has a working function #foo_init' do
2385
+ skip 'Needs testing'
2386
+ end
2387
+ it 'has a working function #foo_interface_static_method' do
2388
+ skip 'Needs testing'
2389
+ end
2390
+ it 'has a working function #foo_method_external_references' do
2391
+ skip 'Needs testing'
2392
+ end
2393
+ it 'has a working function #foo_not_a_constructor_new' do
2394
+ skip 'Needs testing'
2395
+ end
2396
+ it 'has a working function #foo_test_array' do
2397
+ skip 'Needs testing'
2398
+ end
2399
+ it 'has a working function #foo_test_const_char_param' do
2400
+ skip 'Needs testing'
2401
+ end
2402
+ it 'has a working function #foo_test_const_char_retval' do
2403
+ skip 'Needs testing'
2404
+ end
2405
+ it 'has a working function #foo_test_const_struct_param' do
2406
+ skip 'Needs testing'
2407
+ end
2408
+ it 'has a working function #foo_test_const_struct_retval' do
2409
+ skip 'Needs testing'
2410
+ end
2411
+ it 'has a working function #foo_test_string_array' do
2412
+ skip 'Needs testing'
2413
+ end
2414
+ it 'has a working function #foo_test_string_array_with_g' do
2415
+ skip 'Needs testing'
2416
+ end
2417
+ it 'has a working function #foo_test_unsigned_qualifier' do
2418
+ skip 'Needs testing'
2419
+ end
2420
+ it 'has a working function #foo_test_unsigned_type' do
2421
+ skip 'Needs testing'
2422
+ end
1708
2423
  it 'has a working function #func_obj_null_in' do
1709
2424
  Regress.func_obj_null_in nil
1710
2425
  Regress.func_obj_null_in Regress::TestObj.constructor
1711
2426
  pass
1712
2427
  end
1713
2428
 
2429
+ it 'has a working function #func_obj_nullable_in' do
2430
+ Regress.func_obj_null_in nil
2431
+ Regress.func_obj_null_in Regress::TestObj.constructor
2432
+ pass
2433
+ end
2434
+
1714
2435
  it 'has a working function #global_get_flags_out' do
1715
2436
  result = Regress.global_get_flags_out
1716
2437
  result.must_equal Regress::TestFlags[:flag1] | Regress::TestFlags[:flag3]
@@ -1977,6 +2698,13 @@ describe Regress do
1977
2698
  b.must_be_nil
1978
2699
  end
1979
2700
 
2701
+ it 'has a working function #test_callback_return_full' do
2702
+ skip unless get_introspection_data 'Regress', 'test_callback_return_full'
2703
+ obj = Regress::TestObj.constructor
2704
+ Regress.test_callback_return_full proc { obj }
2705
+ ref_count(obj).must_equal 1
2706
+ end
2707
+
1980
2708
  it 'has a working function #test_callback_thaw_async' do
1981
2709
  invoked = []
1982
2710
  Regress.test_callback_async proc { invoked << 1; 1 }, nil
@@ -2220,6 +2948,12 @@ describe Regress do
2220
2948
  list.must_be :==, %w(1 2 3)
2221
2949
  end
2222
2950
 
2951
+ it 'has a working function #test_glist_gtype_container_in' do
2952
+ skip 'Not implemented yet'
2953
+ Regress.test_glist_gtype_container_in %w(1 2 3)
2954
+ pass
2955
+ end
2956
+
2223
2957
  it 'has a working function #test_glist_nothing_in' do
2224
2958
  Regress.test_glist_nothing_in %w(1 2 3)
2225
2959
  pass