|
Last change
on this file since 2236 was 2199, checked in by Bruno Cornec, 9 years ago |
|
Adds a fake test for pb to allow build on older distros
|
|
File size:
618 bytes
|
| Line | |
|---|
| 1 | #!/usr/bin/perl -w
|
|---|
| 2 | #
|
|---|
| 3 | # Tests ProjectBuilder::Base functions
|
|---|
| 4 |
|
|---|
| 5 | use strict;
|
|---|
| 6 | use ProjectBuilder::Filter;
|
|---|
| 7 |
|
|---|
| 8 | eval
|
|---|
| 9 | {
|
|---|
| 10 | require Test::More;
|
|---|
| 11 | Test::More->import();
|
|---|
| 12 | my ($tmv,$tmsv) = split(/\./,$Test::More::VERSION);
|
|---|
| 13 | if ($tmsv lt 87) {
|
|---|
| 14 | die "Test::More is not available in an appropriate version ($tmsv)";
|
|---|
| 15 | }
|
|---|
| 16 | };
|
|---|
| 17 |
|
|---|
| 18 | # Test::More appropriate version not found so no test will be performed here
|
|---|
| 19 | if ($@) {
|
|---|
| 20 | require Test;
|
|---|
| 21 | Test->import();
|
|---|
| 22 | plan(tests => 1);
|
|---|
| 23 | print "# Faking tests as Test::More is not available in an appropriate version\n";
|
|---|
| 24 | ok(1,1);
|
|---|
| 25 | exit(0);
|
|---|
| 26 | }
|
|---|
| 27 |
|
|---|
| 28 | my $nt = 0;
|
|---|
| 29 | is("1", "1", "pb Fake Test");
|
|---|
| 30 | $nt++;
|
|---|
| 31 |
|
|---|
| 32 | done_testing($nt);
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.