1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
|
/* testdeque.c generated by valac 0.18.0, the Vala compiler
* generated from testdeque.vala, do not modify */
/* testdeque.vala
*
* Copyright (C) 2009 Didier Villevalois
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
* Author:
* Didier 'Ptitjes' Villevalois <ptitjes@free.fr>
*/
#include <glib.h>
#include <glib-object.h>
#include <gee.h>
#include <stdlib.h>
#include <string.h>
#define GEE_TYPE_TEST_CASE (gee_test_case_get_type ())
#define GEE_TEST_CASE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GEE_TYPE_TEST_CASE, GeeTestCase))
#define GEE_TEST_CASE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GEE_TYPE_TEST_CASE, GeeTestCaseClass))
#define GEE_IS_TEST_CASE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GEE_TYPE_TEST_CASE))
#define GEE_IS_TEST_CASE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GEE_TYPE_TEST_CASE))
#define GEE_TEST_CASE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GEE_TYPE_TEST_CASE, GeeTestCaseClass))
typedef struct _GeeTestCase GeeTestCase;
typedef struct _GeeTestCaseClass GeeTestCaseClass;
typedef struct _GeeTestCasePrivate GeeTestCasePrivate;
#define TYPE_COLLECTION_TESTS (collection_tests_get_type ())
#define COLLECTION_TESTS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_COLLECTION_TESTS, CollectionTests))
#define COLLECTION_TESTS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_COLLECTION_TESTS, CollectionTestsClass))
#define IS_COLLECTION_TESTS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_COLLECTION_TESTS))
#define IS_COLLECTION_TESTS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_COLLECTION_TESTS))
#define COLLECTION_TESTS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_COLLECTION_TESTS, CollectionTestsClass))
typedef struct _CollectionTests CollectionTests;
typedef struct _CollectionTestsClass CollectionTestsClass;
typedef struct _CollectionTestsPrivate CollectionTestsPrivate;
#define TYPE_QUEUE_TESTS (queue_tests_get_type ())
#define QUEUE_TESTS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_QUEUE_TESTS, QueueTests))
#define QUEUE_TESTS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_QUEUE_TESTS, QueueTestsClass))
#define IS_QUEUE_TESTS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_QUEUE_TESTS))
#define IS_QUEUE_TESTS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_QUEUE_TESTS))
#define QUEUE_TESTS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_QUEUE_TESTS, QueueTestsClass))
typedef struct _QueueTests QueueTests;
typedef struct _QueueTestsClass QueueTestsClass;
typedef struct _QueueTestsPrivate QueueTestsPrivate;
#define TYPE_DEQUE_TESTS (deque_tests_get_type ())
#define DEQUE_TESTS(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_DEQUE_TESTS, DequeTests))
#define DEQUE_TESTS_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_DEQUE_TESTS, DequeTestsClass))
#define IS_DEQUE_TESTS(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_DEQUE_TESTS))
#define IS_DEQUE_TESTS_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_DEQUE_TESTS))
#define DEQUE_TESTS_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_DEQUE_TESTS, DequeTestsClass))
typedef struct _DequeTests DequeTests;
typedef struct _DequeTestsClass DequeTestsClass;
typedef struct _DequeTestsPrivate DequeTestsPrivate;
#define _g_free0(var) (var = (g_free (var), NULL))
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
#define _vala_assert(expr, msg) if G_LIKELY (expr) ; else g_assertion_message_expr (G_LOG_DOMAIN, __FILE__, __LINE__, G_STRFUNC, msg);
struct _GeeTestCase {
GObject parent_instance;
GeeTestCasePrivate * priv;
};
struct _GeeTestCaseClass {
GObjectClass parent_class;
void (*set_up) (GeeTestCase* self);
void (*tear_down) (GeeTestCase* self);
};
struct _CollectionTests {
GeeTestCase parent_instance;
CollectionTestsPrivate * priv;
GeeCollection* test_collection;
};
struct _CollectionTestsClass {
GeeTestCaseClass parent_class;
};
struct _QueueTests {
CollectionTests parent_instance;
QueueTestsPrivate * priv;
};
struct _QueueTestsClass {
CollectionTestsClass parent_class;
};
struct _DequeTests {
QueueTests parent_instance;
DequeTestsPrivate * priv;
};
struct _DequeTestsClass {
QueueTestsClass parent_class;
};
typedef void (*GeeTestCaseTestMethod) (void* user_data);
static gpointer deque_tests_parent_class = NULL;
GType gee_test_case_get_type (void) G_GNUC_CONST;
GType collection_tests_get_type (void) G_GNUC_CONST;
GType queue_tests_get_type (void) G_GNUC_CONST;
GType deque_tests_get_type (void) G_GNUC_CONST;
enum {
DEQUE_TESTS_DUMMY_PROPERTY
};
DequeTests* deque_tests_construct (GType object_type, const gchar* name);
QueueTests* queue_tests_construct (GType object_type, const gchar* name);
void gee_test_case_add_test (GeeTestCase* self, const gchar* name, GeeTestCaseTestMethod test, void* test_target);
void deque_tests_test_queue_use (DequeTests* self);
static void _deque_tests_test_queue_use_gee_test_case_test_method (gpointer self);
void deque_tests_test_stack_use (DequeTests* self);
static void _deque_tests_test_stack_use_gee_test_case_test_method (gpointer self);
void deque_tests_test_reversed_stack_use (DequeTests* self);
static void _deque_tests_test_reversed_stack_use_gee_test_case_test_method (gpointer self);
static void _deque_tests_test_queue_use_gee_test_case_test_method (gpointer self) {
deque_tests_test_queue_use (self);
}
static void _deque_tests_test_stack_use_gee_test_case_test_method (gpointer self) {
deque_tests_test_stack_use (self);
}
static void _deque_tests_test_reversed_stack_use_gee_test_case_test_method (gpointer self) {
deque_tests_test_reversed_stack_use (self);
}
DequeTests* deque_tests_construct (GType object_type, const gchar* name) {
DequeTests * self = NULL;
const gchar* _tmp0_;
g_return_val_if_fail (name != NULL, NULL);
_tmp0_ = name;
self = (DequeTests*) queue_tests_construct (object_type, _tmp0_);
gee_test_case_add_test ((GeeTestCase*) self, "[Deque] queue use", _deque_tests_test_queue_use_gee_test_case_test_method, self);
gee_test_case_add_test ((GeeTestCase*) self, "[Deque] stack use", _deque_tests_test_stack_use_gee_test_case_test_method, self);
gee_test_case_add_test ((GeeTestCase*) self, "[Deque] reversed stack use", _deque_tests_test_reversed_stack_use_gee_test_case_test_method, self);
return self;
}
static gpointer _g_object_ref0 (gpointer self) {
return self ? g_object_ref (self) : NULL;
}
void deque_tests_test_queue_use (DequeTests* self) {
GeeCollection* _tmp0_;
GeeDeque* _tmp1_;
GeeDeque* test_deque;
GeeArrayList* _tmp2_;
GeeArrayList* recipient;
gboolean _tmp3_ = FALSE;
gint _tmp4_;
gint _tmp5_;
gboolean _tmp6_ = FALSE;
gint _tmp7_;
gint _tmp8_;
gboolean _tmp9_ = FALSE;
gint _tmp10_;
gint _tmp11_;
gboolean _tmp12_ = FALSE;
gint _tmp13_;
gint _tmp14_;
gpointer _tmp15_ = NULL;
gchar* _tmp16_;
gpointer _tmp17_ = NULL;
gchar* _tmp18_;
gint _tmp19_;
gint _tmp20_;
gpointer _tmp21_ = NULL;
gchar* _tmp22_;
gpointer _tmp23_ = NULL;
gchar* _tmp24_;
gint _tmp25_;
gint _tmp26_;
gpointer _tmp27_ = NULL;
gchar* _tmp28_;
gpointer _tmp29_ = NULL;
gchar* _tmp30_;
gint _tmp31_;
gint _tmp32_;
gpointer _tmp33_ = NULL;
gchar* _tmp34_;
gpointer _tmp35_ = NULL;
gchar* _tmp36_;
gint _tmp37_;
gint _tmp38_;
gpointer _tmp39_ = NULL;
gchar* _tmp40_;
gpointer _tmp41_ = NULL;
gchar* _tmp42_;
gboolean _tmp43_ = FALSE;
gboolean _tmp44_ = FALSE;
gboolean _tmp45_ = FALSE;
gboolean _tmp46_ = FALSE;
gint _tmp47_;
gint _tmp48_;
gint _tmp49_ = 0;
gint _tmp50_;
gint _tmp51_;
gint _tmp52_;
gint _tmp53_;
gpointer _tmp54_ = NULL;
gchar* _tmp55_;
gint _tmp56_ = 0;
gint _tmp57_;
gint _tmp58_;
gint _tmp59_;
gint _tmp60_;
gpointer _tmp61_ = NULL;
gchar* _tmp62_;
gpointer _tmp63_ = NULL;
gchar* _tmp64_;
gpointer _tmp65_ = NULL;
gchar* _tmp66_;
gint _tmp67_ = 0;
gint _tmp68_;
gint _tmp69_;
gint _tmp70_;
gint _tmp71_;
gint _tmp72_ = 0;
gint _tmp73_;
gint _tmp74_;
gint _tmp75_;
gint _tmp76_;
g_return_if_fail (self != NULL);
_tmp0_ = ((CollectionTests*) self)->test_collection;
_tmp1_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp0_, GEE_TYPE_DEQUE) ? ((GeeDeque*) _tmp0_) : NULL);
test_deque = _tmp1_;
_tmp2_ = gee_array_list_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, NULL);
recipient = _tmp2_;
_vala_assert (test_deque != NULL, "test_deque != null");
_tmp3_ = gee_deque_offer_tail (test_deque, "one");
_vala_assert (_tmp3_, "test_deque.offer_tail (\"one\")");
_tmp4_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp5_ = _tmp4_;
_vala_assert (_tmp5_ == 1, "test_deque.size == 1");
_tmp6_ = gee_deque_offer_tail (test_deque, "two");
_vala_assert (_tmp6_, "test_deque.offer_tail (\"two\")");
_tmp7_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp8_ = _tmp7_;
_vala_assert (_tmp8_ == 2, "test_deque.size == 2");
_tmp9_ = gee_deque_offer_tail (test_deque, "three");
_vala_assert (_tmp9_, "test_deque.offer_tail (\"three\")");
_tmp10_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp11_ = _tmp10_;
_vala_assert (_tmp11_ == 3, "test_deque.size == 3");
_tmp12_ = gee_deque_offer_tail (test_deque, "four");
_vala_assert (_tmp12_, "test_deque.offer_tail (\"four\")");
_tmp13_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp14_ = _tmp13_;
_vala_assert (_tmp14_ == 4, "test_deque.size == 4");
_tmp15_ = gee_deque_peek_head (test_deque);
_tmp16_ = (gchar*) _tmp15_;
_vala_assert (g_strcmp0 (_tmp16_, "one") == 0, "test_deque.peek_head () == \"one\"");
_g_free0 (_tmp16_);
_tmp17_ = gee_deque_poll_head (test_deque);
_tmp18_ = (gchar*) _tmp17_;
_vala_assert (g_strcmp0 (_tmp18_, "one") == 0, "test_deque.poll_head () == \"one\"");
_g_free0 (_tmp18_);
_tmp19_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp20_ = _tmp19_;
_vala_assert (_tmp20_ == 3, "test_deque.size == 3");
_tmp21_ = gee_deque_peek_head (test_deque);
_tmp22_ = (gchar*) _tmp21_;
_vala_assert (g_strcmp0 (_tmp22_, "two") == 0, "test_deque.peek_head () == \"two\"");
_g_free0 (_tmp22_);
_tmp23_ = gee_deque_poll_head (test_deque);
_tmp24_ = (gchar*) _tmp23_;
_vala_assert (g_strcmp0 (_tmp24_, "two") == 0, "test_deque.poll_head () == \"two\"");
_g_free0 (_tmp24_);
_tmp25_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp26_ = _tmp25_;
_vala_assert (_tmp26_ == 2, "test_deque.size == 2");
_tmp27_ = gee_deque_peek_head (test_deque);
_tmp28_ = (gchar*) _tmp27_;
_vala_assert (g_strcmp0 (_tmp28_, "three") == 0, "test_deque.peek_head () == \"three\"");
_g_free0 (_tmp28_);
_tmp29_ = gee_deque_poll_head (test_deque);
_tmp30_ = (gchar*) _tmp29_;
_vala_assert (g_strcmp0 (_tmp30_, "three") == 0, "test_deque.poll_head () == \"three\"");
_g_free0 (_tmp30_);
_tmp31_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp32_ = _tmp31_;
_vala_assert (_tmp32_ == 1, "test_deque.size == 1");
_tmp33_ = gee_deque_peek_head (test_deque);
_tmp34_ = (gchar*) _tmp33_;
_vala_assert (g_strcmp0 (_tmp34_, "four") == 0, "test_deque.peek_head () == \"four\"");
_g_free0 (_tmp34_);
_tmp35_ = gee_deque_poll_head (test_deque);
_tmp36_ = (gchar*) _tmp35_;
_vala_assert (g_strcmp0 (_tmp36_, "four") == 0, "test_deque.poll_head () == \"four\"");
_g_free0 (_tmp36_);
_tmp37_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp38_ = _tmp37_;
_vala_assert (_tmp38_ == 0, "test_deque.size == 0");
_tmp39_ = gee_deque_peek_head (test_deque);
_tmp40_ = (gchar*) _tmp39_;
_vala_assert (_tmp40_ == NULL, "test_deque.peek_head () == null");
_g_free0 (_tmp40_);
_tmp41_ = gee_deque_poll_head (test_deque);
_tmp42_ = (gchar*) _tmp41_;
_vala_assert (_tmp42_ == NULL, "test_deque.poll_head () == null");
_g_free0 (_tmp42_);
gee_abstract_collection_clear ((GeeAbstractCollection*) recipient);
_tmp43_ = gee_deque_offer_tail (test_deque, "one");
_vala_assert (_tmp43_, "test_deque.offer_tail (\"one\")");
_tmp44_ = gee_deque_offer_tail (test_deque, "two");
_vala_assert (_tmp44_, "test_deque.offer_tail (\"two\")");
_tmp45_ = gee_deque_offer_tail (test_deque, "three");
_vala_assert (_tmp45_, "test_deque.offer_tail (\"three\")");
_tmp46_ = gee_deque_offer_tail (test_deque, "four");
_vala_assert (_tmp46_, "test_deque.offer_tail (\"four\")");
_tmp47_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp48_ = _tmp47_;
_vala_assert (_tmp48_ == 4, "test_deque.size == 4");
_tmp49_ = gee_deque_drain_head (test_deque, (GeeCollection*) recipient, 1);
_vala_assert (_tmp49_ == 1, "test_deque.drain_head (recipient, 1) == 1");
_tmp50_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp51_ = _tmp50_;
_vala_assert (_tmp51_ == 3, "test_deque.size == 3");
_tmp52_ = gee_abstract_collection_get_size ((GeeCollection*) recipient);
_tmp53_ = _tmp52_;
_vala_assert (_tmp53_ == 1, "recipient.size == 1");
_tmp54_ = gee_abstract_list_get ((GeeAbstractList*) recipient, 0);
_tmp55_ = (gchar*) _tmp54_;
_vala_assert (g_strcmp0 (_tmp55_, "one") == 0, "recipient.get (0) == \"one\"");
_g_free0 (_tmp55_);
_tmp56_ = gee_deque_drain_head (test_deque, (GeeCollection*) recipient, -1);
_vala_assert (_tmp56_ == 3, "test_deque.drain_head (recipient) == 3");
_tmp57_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp58_ = _tmp57_;
_vala_assert (_tmp58_ == 0, "test_deque.size == 0");
_tmp59_ = gee_abstract_collection_get_size ((GeeCollection*) recipient);
_tmp60_ = _tmp59_;
_vala_assert (_tmp60_ == 4, "recipient.size == 4");
_tmp61_ = gee_abstract_list_get ((GeeAbstractList*) recipient, 1);
_tmp62_ = (gchar*) _tmp61_;
_vala_assert (g_strcmp0 (_tmp62_, "two") == 0, "recipient.get (1) == \"two\"");
_g_free0 (_tmp62_);
_tmp63_ = gee_abstract_list_get ((GeeAbstractList*) recipient, 2);
_tmp64_ = (gchar*) _tmp63_;
_vala_assert (g_strcmp0 (_tmp64_, "three") == 0, "recipient.get (2) == \"three\"");
_g_free0 (_tmp64_);
_tmp65_ = gee_abstract_list_get ((GeeAbstractList*) recipient, 3);
_tmp66_ = (gchar*) _tmp65_;
_vala_assert (g_strcmp0 (_tmp66_, "four") == 0, "recipient.get (3) == \"four\"");
_g_free0 (_tmp66_);
gee_abstract_collection_clear ((GeeAbstractCollection*) recipient);
_tmp67_ = gee_deque_drain_head (test_deque, (GeeCollection*) recipient, 1);
_vala_assert (_tmp67_ == 0, "test_deque.drain_head (recipient, 1) == 0");
_tmp68_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp69_ = _tmp68_;
_vala_assert (_tmp69_ == 0, "test_deque.size == 0");
_tmp70_ = gee_abstract_collection_get_size ((GeeCollection*) recipient);
_tmp71_ = _tmp70_;
_vala_assert (_tmp71_ == 0, "recipient.size == 0");
gee_abstract_collection_clear ((GeeAbstractCollection*) recipient);
_tmp72_ = gee_deque_drain_head (test_deque, (GeeCollection*) recipient, -1);
_vala_assert (_tmp72_ == 0, "test_deque.drain_head (recipient) == 0");
_tmp73_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp74_ = _tmp73_;
_vala_assert (_tmp74_ == 0, "test_deque.size == 0");
_tmp75_ = gee_abstract_collection_get_size ((GeeCollection*) recipient);
_tmp76_ = _tmp75_;
_vala_assert (_tmp76_ == 0, "recipient.size == 0");
_g_object_unref0 (recipient);
_g_object_unref0 (test_deque);
}
void deque_tests_test_stack_use (DequeTests* self) {
GeeCollection* _tmp0_;
GeeDeque* _tmp1_;
GeeDeque* test_deque;
GeeArrayList* _tmp2_;
GeeArrayList* recipient;
gboolean _tmp3_ = FALSE;
gint _tmp4_;
gint _tmp5_;
gboolean _tmp6_ = FALSE;
gint _tmp7_;
gint _tmp8_;
gboolean _tmp9_ = FALSE;
gint _tmp10_;
gint _tmp11_;
gboolean _tmp12_ = FALSE;
gint _tmp13_;
gint _tmp14_;
gpointer _tmp15_ = NULL;
gchar* _tmp16_;
gpointer _tmp17_ = NULL;
gchar* _tmp18_;
gint _tmp19_;
gint _tmp20_;
gpointer _tmp21_ = NULL;
gchar* _tmp22_;
gpointer _tmp23_ = NULL;
gchar* _tmp24_;
gint _tmp25_;
gint _tmp26_;
gpointer _tmp27_ = NULL;
gchar* _tmp28_;
gpointer _tmp29_ = NULL;
gchar* _tmp30_;
gint _tmp31_;
gint _tmp32_;
gpointer _tmp33_ = NULL;
gchar* _tmp34_;
gpointer _tmp35_ = NULL;
gchar* _tmp36_;
gint _tmp37_;
gint _tmp38_;
gpointer _tmp39_ = NULL;
gchar* _tmp40_;
gpointer _tmp41_ = NULL;
gchar* _tmp42_;
gboolean _tmp43_ = FALSE;
gboolean _tmp44_ = FALSE;
gboolean _tmp45_ = FALSE;
gboolean _tmp46_ = FALSE;
gint _tmp47_;
gint _tmp48_;
gint _tmp49_ = 0;
gint _tmp50_;
gint _tmp51_;
gint _tmp52_;
gint _tmp53_;
gpointer _tmp54_ = NULL;
gchar* _tmp55_;
gint _tmp56_ = 0;
gint _tmp57_;
gint _tmp58_;
gint _tmp59_;
gint _tmp60_;
gpointer _tmp61_ = NULL;
gchar* _tmp62_;
gpointer _tmp63_ = NULL;
gchar* _tmp64_;
gpointer _tmp65_ = NULL;
gchar* _tmp66_;
gint _tmp67_ = 0;
gint _tmp68_;
gint _tmp69_;
gint _tmp70_;
gint _tmp71_;
gint _tmp72_ = 0;
gint _tmp73_;
gint _tmp74_;
gint _tmp75_;
gint _tmp76_;
g_return_if_fail (self != NULL);
_tmp0_ = ((CollectionTests*) self)->test_collection;
_tmp1_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp0_, GEE_TYPE_DEQUE) ? ((GeeDeque*) _tmp0_) : NULL);
test_deque = _tmp1_;
_tmp2_ = gee_array_list_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, NULL);
recipient = _tmp2_;
_vala_assert (test_deque != NULL, "test_deque != null");
_tmp3_ = gee_deque_offer_head (test_deque, "one");
_vala_assert (_tmp3_, "test_deque.offer_head (\"one\")");
_tmp4_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp5_ = _tmp4_;
_vala_assert (_tmp5_ == 1, "test_deque.size == 1");
_tmp6_ = gee_deque_offer_head (test_deque, "two");
_vala_assert (_tmp6_, "test_deque.offer_head (\"two\")");
_tmp7_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp8_ = _tmp7_;
_vala_assert (_tmp8_ == 2, "test_deque.size == 2");
_tmp9_ = gee_deque_offer_head (test_deque, "three");
_vala_assert (_tmp9_, "test_deque.offer_head (\"three\")");
_tmp10_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp11_ = _tmp10_;
_vala_assert (_tmp11_ == 3, "test_deque.size == 3");
_tmp12_ = gee_deque_offer_head (test_deque, "four");
_vala_assert (_tmp12_, "test_deque.offer_head (\"four\")");
_tmp13_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp14_ = _tmp13_;
_vala_assert (_tmp14_ == 4, "test_deque.size == 4");
_tmp15_ = gee_deque_peek_head (test_deque);
_tmp16_ = (gchar*) _tmp15_;
_vala_assert (g_strcmp0 (_tmp16_, "four") == 0, "test_deque.peek_head () == \"four\"");
_g_free0 (_tmp16_);
_tmp17_ = gee_deque_poll_head (test_deque);
_tmp18_ = (gchar*) _tmp17_;
_vala_assert (g_strcmp0 (_tmp18_, "four") == 0, "test_deque.poll_head () == \"four\"");
_g_free0 (_tmp18_);
_tmp19_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp20_ = _tmp19_;
_vala_assert (_tmp20_ == 3, "test_deque.size == 3");
_tmp21_ = gee_deque_peek_head (test_deque);
_tmp22_ = (gchar*) _tmp21_;
_vala_assert (g_strcmp0 (_tmp22_, "three") == 0, "test_deque.peek_head () == \"three\"");
_g_free0 (_tmp22_);
_tmp23_ = gee_deque_poll_head (test_deque);
_tmp24_ = (gchar*) _tmp23_;
_vala_assert (g_strcmp0 (_tmp24_, "three") == 0, "test_deque.poll_head () == \"three\"");
_g_free0 (_tmp24_);
_tmp25_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp26_ = _tmp25_;
_vala_assert (_tmp26_ == 2, "test_deque.size == 2");
_tmp27_ = gee_deque_peek_head (test_deque);
_tmp28_ = (gchar*) _tmp27_;
_vala_assert (g_strcmp0 (_tmp28_, "two") == 0, "test_deque.peek_head () == \"two\"");
_g_free0 (_tmp28_);
_tmp29_ = gee_deque_poll_head (test_deque);
_tmp30_ = (gchar*) _tmp29_;
_vala_assert (g_strcmp0 (_tmp30_, "two") == 0, "test_deque.poll_head () == \"two\"");
_g_free0 (_tmp30_);
_tmp31_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp32_ = _tmp31_;
_vala_assert (_tmp32_ == 1, "test_deque.size == 1");
_tmp33_ = gee_deque_peek_head (test_deque);
_tmp34_ = (gchar*) _tmp33_;
_vala_assert (g_strcmp0 (_tmp34_, "one") == 0, "test_deque.peek_head () == \"one\"");
_g_free0 (_tmp34_);
_tmp35_ = gee_deque_poll_head (test_deque);
_tmp36_ = (gchar*) _tmp35_;
_vala_assert (g_strcmp0 (_tmp36_, "one") == 0, "test_deque.poll_head () == \"one\"");
_g_free0 (_tmp36_);
_tmp37_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp38_ = _tmp37_;
_vala_assert (_tmp38_ == 0, "test_deque.size == 0");
_tmp39_ = gee_deque_peek_head (test_deque);
_tmp40_ = (gchar*) _tmp39_;
_vala_assert (_tmp40_ == NULL, "test_deque.peek_head () == null");
_g_free0 (_tmp40_);
_tmp41_ = gee_deque_poll_head (test_deque);
_tmp42_ = (gchar*) _tmp41_;
_vala_assert (_tmp42_ == NULL, "test_deque.poll_head () == null");
_g_free0 (_tmp42_);
gee_abstract_collection_clear ((GeeAbstractCollection*) recipient);
_tmp43_ = gee_deque_offer_head (test_deque, "one");
_vala_assert (_tmp43_, "test_deque.offer_head (\"one\")");
_tmp44_ = gee_deque_offer_head (test_deque, "two");
_vala_assert (_tmp44_, "test_deque.offer_head (\"two\")");
_tmp45_ = gee_deque_offer_head (test_deque, "three");
_vala_assert (_tmp45_, "test_deque.offer_head (\"three\")");
_tmp46_ = gee_deque_offer_head (test_deque, "four");
_vala_assert (_tmp46_, "test_deque.offer_head (\"four\")");
_tmp47_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp48_ = _tmp47_;
_vala_assert (_tmp48_ == 4, "test_deque.size == 4");
_tmp49_ = gee_deque_drain_head (test_deque, (GeeCollection*) recipient, 1);
_vala_assert (_tmp49_ == 1, "test_deque.drain_head (recipient, 1) == 1");
_tmp50_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp51_ = _tmp50_;
_vala_assert (_tmp51_ == 3, "test_deque.size == 3");
_tmp52_ = gee_abstract_collection_get_size ((GeeCollection*) recipient);
_tmp53_ = _tmp52_;
_vala_assert (_tmp53_ == 1, "recipient.size == 1");
_tmp54_ = gee_abstract_list_get ((GeeAbstractList*) recipient, 0);
_tmp55_ = (gchar*) _tmp54_;
_vala_assert (g_strcmp0 (_tmp55_, "four") == 0, "recipient.get (0) == \"four\"");
_g_free0 (_tmp55_);
_tmp56_ = gee_deque_drain_head (test_deque, (GeeCollection*) recipient, -1);
_vala_assert (_tmp56_ == 3, "test_deque.drain_head (recipient) == 3");
_tmp57_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp58_ = _tmp57_;
_vala_assert (_tmp58_ == 0, "test_deque.size == 0");
_tmp59_ = gee_abstract_collection_get_size ((GeeCollection*) recipient);
_tmp60_ = _tmp59_;
_vala_assert (_tmp60_ == 4, "recipient.size == 4");
_tmp61_ = gee_abstract_list_get ((GeeAbstractList*) recipient, 1);
_tmp62_ = (gchar*) _tmp61_;
_vala_assert (g_strcmp0 (_tmp62_, "three") == 0, "recipient.get (1) == \"three\"");
_g_free0 (_tmp62_);
_tmp63_ = gee_abstract_list_get ((GeeAbstractList*) recipient, 2);
_tmp64_ = (gchar*) _tmp63_;
_vala_assert (g_strcmp0 (_tmp64_, "two") == 0, "recipient.get (2) == \"two\"");
_g_free0 (_tmp64_);
_tmp65_ = gee_abstract_list_get ((GeeAbstractList*) recipient, 3);
_tmp66_ = (gchar*) _tmp65_;
_vala_assert (g_strcmp0 (_tmp66_, "one") == 0, "recipient.get (3) == \"one\"");
_g_free0 (_tmp66_);
gee_abstract_collection_clear ((GeeAbstractCollection*) recipient);
_tmp67_ = gee_deque_drain_head (test_deque, (GeeCollection*) recipient, 1);
_vala_assert (_tmp67_ == 0, "test_deque.drain_head (recipient, 1) == 0");
_tmp68_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp69_ = _tmp68_;
_vala_assert (_tmp69_ == 0, "test_deque.size == 0");
_tmp70_ = gee_abstract_collection_get_size ((GeeCollection*) recipient);
_tmp71_ = _tmp70_;
_vala_assert (_tmp71_ == 0, "recipient.size == 0");
gee_abstract_collection_clear ((GeeAbstractCollection*) recipient);
_tmp72_ = gee_deque_drain_head (test_deque, (GeeCollection*) recipient, -1);
_vala_assert (_tmp72_ == 0, "test_deque.drain_head (recipient) == 0");
_tmp73_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp74_ = _tmp73_;
_vala_assert (_tmp74_ == 0, "test_deque.size == 0");
_tmp75_ = gee_abstract_collection_get_size ((GeeCollection*) recipient);
_tmp76_ = _tmp75_;
_vala_assert (_tmp76_ == 0, "recipient.size == 0");
_g_object_unref0 (recipient);
_g_object_unref0 (test_deque);
}
void deque_tests_test_reversed_stack_use (DequeTests* self) {
GeeCollection* _tmp0_;
GeeDeque* _tmp1_;
GeeDeque* test_deque;
GeeArrayList* _tmp2_;
GeeArrayList* recipient;
gboolean _tmp3_ = FALSE;
gint _tmp4_;
gint _tmp5_;
gboolean _tmp6_ = FALSE;
gint _tmp7_;
gint _tmp8_;
gboolean _tmp9_ = FALSE;
gint _tmp10_;
gint _tmp11_;
gboolean _tmp12_ = FALSE;
gint _tmp13_;
gint _tmp14_;
gpointer _tmp15_ = NULL;
gchar* _tmp16_;
gpointer _tmp17_ = NULL;
gchar* _tmp18_;
gint _tmp19_;
gint _tmp20_;
gpointer _tmp21_ = NULL;
gchar* _tmp22_;
gpointer _tmp23_ = NULL;
gchar* _tmp24_;
gint _tmp25_;
gint _tmp26_;
gpointer _tmp27_ = NULL;
gchar* _tmp28_;
gpointer _tmp29_ = NULL;
gchar* _tmp30_;
gint _tmp31_;
gint _tmp32_;
gpointer _tmp33_ = NULL;
gchar* _tmp34_;
gpointer _tmp35_ = NULL;
gchar* _tmp36_;
gint _tmp37_;
gint _tmp38_;
gpointer _tmp39_ = NULL;
gchar* _tmp40_;
gpointer _tmp41_ = NULL;
gchar* _tmp42_;
gboolean _tmp43_ = FALSE;
gboolean _tmp44_ = FALSE;
gboolean _tmp45_ = FALSE;
gboolean _tmp46_ = FALSE;
gint _tmp47_;
gint _tmp48_;
gint _tmp49_ = 0;
gint _tmp50_;
gint _tmp51_;
gint _tmp52_;
gint _tmp53_;
gpointer _tmp54_ = NULL;
gchar* _tmp55_;
gint _tmp56_ = 0;
gint _tmp57_;
gint _tmp58_;
gint _tmp59_;
gint _tmp60_;
gpointer _tmp61_ = NULL;
gchar* _tmp62_;
gpointer _tmp63_ = NULL;
gchar* _tmp64_;
gpointer _tmp65_ = NULL;
gchar* _tmp66_;
gint _tmp67_ = 0;
gint _tmp68_;
gint _tmp69_;
gint _tmp70_;
gint _tmp71_;
gint _tmp72_ = 0;
gint _tmp73_;
gint _tmp74_;
gint _tmp75_;
gint _tmp76_;
g_return_if_fail (self != NULL);
_tmp0_ = ((CollectionTests*) self)->test_collection;
_tmp1_ = _g_object_ref0 (G_TYPE_CHECK_INSTANCE_TYPE (_tmp0_, GEE_TYPE_DEQUE) ? ((GeeDeque*) _tmp0_) : NULL);
test_deque = _tmp1_;
_tmp2_ = gee_array_list_new (G_TYPE_STRING, (GBoxedCopyFunc) g_strdup, g_free, NULL);
recipient = _tmp2_;
_vala_assert (test_deque != NULL, "test_deque != null");
_tmp3_ = gee_deque_offer_tail (test_deque, "one");
_vala_assert (_tmp3_, "test_deque.offer_tail (\"one\")");
_tmp4_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp5_ = _tmp4_;
_vala_assert (_tmp5_ == 1, "test_deque.size == 1");
_tmp6_ = gee_deque_offer_tail (test_deque, "two");
_vala_assert (_tmp6_, "test_deque.offer_tail (\"two\")");
_tmp7_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp8_ = _tmp7_;
_vala_assert (_tmp8_ == 2, "test_deque.size == 2");
_tmp9_ = gee_deque_offer_tail (test_deque, "three");
_vala_assert (_tmp9_, "test_deque.offer_tail (\"three\")");
_tmp10_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp11_ = _tmp10_;
_vala_assert (_tmp11_ == 3, "test_deque.size == 3");
_tmp12_ = gee_deque_offer_tail (test_deque, "four");
_vala_assert (_tmp12_, "test_deque.offer_tail (\"four\")");
_tmp13_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp14_ = _tmp13_;
_vala_assert (_tmp14_ == 4, "test_deque.size == 4");
_tmp15_ = gee_deque_peek_tail (test_deque);
_tmp16_ = (gchar*) _tmp15_;
_vala_assert (g_strcmp0 (_tmp16_, "four") == 0, "test_deque.peek_tail () == \"four\"");
_g_free0 (_tmp16_);
_tmp17_ = gee_deque_poll_tail (test_deque);
_tmp18_ = (gchar*) _tmp17_;
_vala_assert (g_strcmp0 (_tmp18_, "four") == 0, "test_deque.poll_tail () == \"four\"");
_g_free0 (_tmp18_);
_tmp19_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp20_ = _tmp19_;
_vala_assert (_tmp20_ == 3, "test_deque.size == 3");
_tmp21_ = gee_deque_peek_tail (test_deque);
_tmp22_ = (gchar*) _tmp21_;
_vala_assert (g_strcmp0 (_tmp22_, "three") == 0, "test_deque.peek_tail () == \"three\"");
_g_free0 (_tmp22_);
_tmp23_ = gee_deque_poll_tail (test_deque);
_tmp24_ = (gchar*) _tmp23_;
_vala_assert (g_strcmp0 (_tmp24_, "three") == 0, "test_deque.poll_tail () == \"three\"");
_g_free0 (_tmp24_);
_tmp25_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp26_ = _tmp25_;
_vala_assert (_tmp26_ == 2, "test_deque.size == 2");
_tmp27_ = gee_deque_peek_tail (test_deque);
_tmp28_ = (gchar*) _tmp27_;
_vala_assert (g_strcmp0 (_tmp28_, "two") == 0, "test_deque.peek_tail () == \"two\"");
_g_free0 (_tmp28_);
_tmp29_ = gee_deque_poll_tail (test_deque);
_tmp30_ = (gchar*) _tmp29_;
_vala_assert (g_strcmp0 (_tmp30_, "two") == 0, "test_deque.poll_tail () == \"two\"");
_g_free0 (_tmp30_);
_tmp31_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp32_ = _tmp31_;
_vala_assert (_tmp32_ == 1, "test_deque.size == 1");
_tmp33_ = gee_deque_peek_tail (test_deque);
_tmp34_ = (gchar*) _tmp33_;
_vala_assert (g_strcmp0 (_tmp34_, "one") == 0, "test_deque.peek_tail () == \"one\"");
_g_free0 (_tmp34_);
_tmp35_ = gee_deque_poll_tail (test_deque);
_tmp36_ = (gchar*) _tmp35_;
_vala_assert (g_strcmp0 (_tmp36_, "one") == 0, "test_deque.poll_tail () == \"one\"");
_g_free0 (_tmp36_);
_tmp37_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp38_ = _tmp37_;
_vala_assert (_tmp38_ == 0, "test_deque.size == 0");
_tmp39_ = gee_deque_peek_tail (test_deque);
_tmp40_ = (gchar*) _tmp39_;
_vala_assert (_tmp40_ == NULL, "test_deque.peek_tail () == null");
_g_free0 (_tmp40_);
_tmp41_ = gee_deque_poll_tail (test_deque);
_tmp42_ = (gchar*) _tmp41_;
_vala_assert (_tmp42_ == NULL, "test_deque.poll_tail () == null");
_g_free0 (_tmp42_);
gee_abstract_collection_clear ((GeeAbstractCollection*) recipient);
_tmp43_ = gee_deque_offer_tail (test_deque, "one");
_vala_assert (_tmp43_, "test_deque.offer_tail (\"one\")");
_tmp44_ = gee_deque_offer_tail (test_deque, "two");
_vala_assert (_tmp44_, "test_deque.offer_tail (\"two\")");
_tmp45_ = gee_deque_offer_tail (test_deque, "three");
_vala_assert (_tmp45_, "test_deque.offer_tail (\"three\")");
_tmp46_ = gee_deque_offer_tail (test_deque, "four");
_vala_assert (_tmp46_, "test_deque.offer_tail (\"four\")");
_tmp47_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp48_ = _tmp47_;
_vala_assert (_tmp48_ == 4, "test_deque.size == 4");
_tmp49_ = gee_deque_drain_tail (test_deque, (GeeCollection*) recipient, 1);
_vala_assert (_tmp49_ == 1, "test_deque.drain_tail (recipient, 1) == 1");
_tmp50_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp51_ = _tmp50_;
_vala_assert (_tmp51_ == 3, "test_deque.size == 3");
_tmp52_ = gee_abstract_collection_get_size ((GeeCollection*) recipient);
_tmp53_ = _tmp52_;
_vala_assert (_tmp53_ == 1, "recipient.size == 1");
_tmp54_ = gee_abstract_list_get ((GeeAbstractList*) recipient, 0);
_tmp55_ = (gchar*) _tmp54_;
_vala_assert (g_strcmp0 (_tmp55_, "four") == 0, "recipient.get (0) == \"four\"");
_g_free0 (_tmp55_);
_tmp56_ = gee_deque_drain_tail (test_deque, (GeeCollection*) recipient, -1);
_vala_assert (_tmp56_ == 3, "test_deque.drain_tail (recipient) == 3");
_tmp57_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp58_ = _tmp57_;
_vala_assert (_tmp58_ == 0, "test_deque.size == 0");
_tmp59_ = gee_abstract_collection_get_size ((GeeCollection*) recipient);
_tmp60_ = _tmp59_;
_vala_assert (_tmp60_ == 4, "recipient.size == 4");
_tmp61_ = gee_abstract_list_get ((GeeAbstractList*) recipient, 1);
_tmp62_ = (gchar*) _tmp61_;
_vala_assert (g_strcmp0 (_tmp62_, "three") == 0, "recipient.get (1) == \"three\"");
_g_free0 (_tmp62_);
_tmp63_ = gee_abstract_list_get ((GeeAbstractList*) recipient, 2);
_tmp64_ = (gchar*) _tmp63_;
_vala_assert (g_strcmp0 (_tmp64_, "two") == 0, "recipient.get (2) == \"two\"");
_g_free0 (_tmp64_);
_tmp65_ = gee_abstract_list_get ((GeeAbstractList*) recipient, 3);
_tmp66_ = (gchar*) _tmp65_;
_vala_assert (g_strcmp0 (_tmp66_, "one") == 0, "recipient.get (3) == \"one\"");
_g_free0 (_tmp66_);
gee_abstract_collection_clear ((GeeAbstractCollection*) recipient);
_tmp67_ = gee_deque_drain_tail (test_deque, (GeeCollection*) recipient, 1);
_vala_assert (_tmp67_ == 0, "test_deque.drain_tail (recipient, 1) == 0");
_tmp68_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp69_ = _tmp68_;
_vala_assert (_tmp69_ == 0, "test_deque.size == 0");
_tmp70_ = gee_abstract_collection_get_size ((GeeCollection*) recipient);
_tmp71_ = _tmp70_;
_vala_assert (_tmp71_ == 0, "recipient.size == 0");
gee_abstract_collection_clear ((GeeAbstractCollection*) recipient);
_tmp72_ = gee_deque_drain_tail (test_deque, (GeeCollection*) recipient, -1);
_vala_assert (_tmp72_ == 0, "test_deque.drain_tail (recipient) == 0");
_tmp73_ = gee_collection_get_size ((GeeCollection*) test_deque);
_tmp74_ = _tmp73_;
_vala_assert (_tmp74_ == 0, "test_deque.size == 0");
_tmp75_ = gee_abstract_collection_get_size ((GeeCollection*) recipient);
_tmp76_ = _tmp75_;
_vala_assert (_tmp76_ == 0, "recipient.size == 0");
_g_object_unref0 (recipient);
_g_object_unref0 (test_deque);
}
static void deque_tests_class_init (DequeTestsClass * klass) {
deque_tests_parent_class = g_type_class_peek_parent (klass);
}
static void deque_tests_instance_init (DequeTests * self) {
}
GType deque_tests_get_type (void) {
static volatile gsize deque_tests_type_id__volatile = 0;
if (g_once_init_enter (&deque_tests_type_id__volatile)) {
static const GTypeInfo g_define_type_info = { sizeof (DequeTestsClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) deque_tests_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (DequeTests), 0, (GInstanceInitFunc) deque_tests_instance_init, NULL };
GType deque_tests_type_id;
deque_tests_type_id = g_type_register_static (TYPE_QUEUE_TESTS, "DequeTests", &g_define_type_info, G_TYPE_FLAG_ABSTRACT);
g_once_init_leave (&deque_tests_type_id__volatile, deque_tests_type_id);
}
return deque_tests_type_id__volatile;
}
|