PageRenderTime 94ms CodeModel.GetById 32ms RepoModel.GetById 0ms app.codeStats 0ms

/trunk/Examples/test-suite/perl5/voidtest_runme.pl

#
Perl | 20 lines | 18 code | 1 blank | 1 comment | 0 complexity | cacaf22e5502715277909fce5f291e3a MD5 | raw file
Possible License(s): LGPL-2.1, Cube, GPL-3.0, 0BSD, GPL-2.0
  1. use strict;
  2. use warnings;
  3. use Test::More tests => 7;
  4. BEGIN { use_ok('voidtest') }
  5. require_ok('voidtest');
  6. # adapted from ../python/voidtest_runme.py
  7. voidtest::globalfunc();
  8. my $f = voidtest::Foo->new();
  9. is($f->memberfunc(), undef);
  10. { local $TODO = "opaque pointers hidden behind layer of indirection";
  11. my $v1 = voidtest::vfunc1($f);
  12. my $v2 = voidtest::vfunc2($f);
  13. is($v1, $v2);
  14. my $v3 = voidtest::vfunc3($v1);
  15. is($v3->this, $f->this);
  16. my $v4 = voidtest::vfunc4($f);
  17. is($v1, $v4);
  18. }
  19. ok(1, "done");