GUI.t 766 B

12345678910111213141516171819202122232425262728293031323334
  1. #!/usr/bin/perl
  2. use strict;
  3. use warnings;
  4. use Test::More qw{no_plan};
  5. main();
  6. sub main {
  7. my $class = 'Fcm::Interactive::InputGetter::GUI';
  8. use_ok($class);
  9. test_constructor($class);
  10. }
  11. ################################################################################
  12. # Tests usage of constructor
  13. sub test_constructor {
  14. my ($class) = @_;
  15. my $prefix = 'constructor';
  16. my $input_getter = $class->new({
  17. title => 'title-value',
  18. message => 'message-value',
  19. type => 'type-value',
  20. default => 'default-value',
  21. geometry => 'geometry-value',
  22. });
  23. isa_ok($input_getter, $class);
  24. is($input_getter->get_geometry(), 'geometry-value', "$prefix: geometry");
  25. }
  26. # TODO: tests the invoke method
  27. __END__