Skip to content

Commit

Permalink
Use Cpanel::JSON::XS::true() in tests
Browse files Browse the repository at this point in the history
  • Loading branch information
oalders committed Oct 27, 2017
1 parent 0c21c04 commit 90014a1
Show file tree
Hide file tree
Showing 22 changed files with 54 additions and 67 deletions.
2 changes: 0 additions & 2 deletions t/00_setup.t
@@ -1,8 +1,6 @@
use strict;
use warnings;

use lib 't/lib';

use CPAN::Faker 0.010;
use Devel::Confess;
use File::Copy qw( copy );
Expand Down
2 changes: 0 additions & 2 deletions t/01_darkpan.t
@@ -1,8 +1,6 @@
use strict;
use warnings;

use lib 't/lib';

use Devel::Confess;
use MetaCPAN::DarkPAN;
use MetaCPAN::TestServer;
Expand Down
8 changes: 4 additions & 4 deletions t/release/badpod.t
@@ -1,9 +1,9 @@
use Test::More;
use strict;
use warnings;

use lib 't/lib';
use Cpanel::JSON::XS ();
use MetaCPAN::TestHelpers;
use Test::More;

test_release(
{
Expand All @@ -17,8 +17,8 @@ test_release(
'lib/BadPod.pm' => [
{
name => 'BadPod',
indexed => 'true',
authorized => 'true',
indexed => Cpanel::JSON::XS::true(),
authorized => Cpanel::JSON::XS::true(),
version => '0.01',
version_numified => 0.01,
associated_pod => 'MO/BadPod-0.01/lib/BadPod.pm',
Expand Down
10 changes: 5 additions & 5 deletions t/release/binary-data.t
@@ -1,7 +1,7 @@
use strict;
use warnings;

use lib 't/lib';
use Cpanel::JSON::XS ();
use MetaCPAN::TestHelpers;
use Test::More;

Expand All @@ -17,8 +17,8 @@ test_release(
'lib/Binary/Data.pm' => [
{
name => 'Binary::Data',
indexed => 'true',
authorized => 'true',
indexed => Cpanel::JSON::XS::true(),
authorized => Cpanel::JSON::XS::true(),
version => '0.01',
version_numified => 0.01,
associated_pod => undef,
Expand All @@ -27,8 +27,8 @@ test_release(
'lib/Binary/Data/WithPod.pm' => [
{
name => 'Binary::Data::WithPod',
indexed => 'true',
authorized => 'true',
indexed => Cpanel::JSON::XS::true(),
authorized => Cpanel::JSON::XS::true(),
version => '0.02',
version_numified => 0.02,
associated_pod =>
Expand Down
8 changes: 4 additions & 4 deletions t/release/common-files.t
@@ -1,9 +1,9 @@
use Test::More;
use strict;
use warnings;

use lib 't/lib';
use Cpanel::JSON::XS ();
use MetaCPAN::TestHelpers;
use Test::More;

test_release(
{
Expand All @@ -16,8 +16,8 @@ test_release(
'lib/Common/Files.pm' => [
{
name => 'Common::Files',
indexed => 'true',
authorized => 'true',
indexed => Cpanel::JSON::XS::true(),
authorized => Cpanel::JSON::XS::true(),
version => '1.1',
version_numified => 1.1,
associated_pod =>
Expand Down
3 changes: 1 addition & 2 deletions t/release/devel-gofaster-0.000.t
@@ -1,9 +1,8 @@
use Test::More;
use strict;
use warnings;

use lib 't/lib';
use MetaCPAN::TestHelpers;
use Test::More;

test_release(
{
Expand Down
19 changes: 10 additions & 9 deletions t/release/file-duplicates.t
@@ -1,6 +1,7 @@
use strict;
use warnings;

use Cpanel::JSON::XS ();
use MetaCPAN::Server::Test;
use MetaCPAN::TestHelpers;
use Test::More;
Expand All @@ -16,8 +17,8 @@ test_release(
name => 'File::Duplicates',
version => '0.991',
version_numified => '0.991',
authorized => 'true',
indexed => 'true',
authorized => Cpanel::JSON::XS::true(),
indexed => Cpanel::JSON::XS::true(),
associated_pod => undef,
}
],
Expand All @@ -26,8 +27,8 @@ test_release(
name => 'File::lib::File::Duplicates',
version => '0.992',
version_numified => '0.992',
authorized => 'true',
indexed => 'true',
authorized => Cpanel::JSON::XS::true(),
indexed => Cpanel::JSON::XS::true(),
associated_pod => undef,
}
],
Expand All @@ -36,7 +37,7 @@ test_release(
name => 'Dupe',
version => '0.993',
version_numified => '0.993',
authorized => 'true',
authorized => Cpanel::JSON::XS::true(),
indexed => 0,
associated_pod => undef,
}
Expand All @@ -46,16 +47,16 @@ test_release(
name => 'DupeX::Dupe',
version => '0.994',
version_numified => '0.994',
authorized => 'true',
indexed => 'true',
authorized => Cpanel::JSON::XS::true(),
indexed => Cpanel::JSON::XS::true(),
associated_pod => undef,
},
{
name => 'DupeX::Dupe::X',
version => '0.995',
version_numified => '0.995',
authorized => 'true',
indexed => 'true',
authorized => Cpanel::JSON::XS::true(),
indexed => Cpanel::JSON::XS::true(),
associated_pod => undef,
}
],
Expand Down
3 changes: 1 addition & 2 deletions t/release/ipsonar-0.29.t
@@ -1,9 +1,8 @@
use Test::More;
use strict;
use warnings;

use lib 't/lib';
use MetaCPAN::TestHelpers;
use Test::More;

test_release(
{
Expand Down
6 changes: 3 additions & 3 deletions t/release/local-lib.t
@@ -1,7 +1,7 @@
use strict;
use warnings;

use lib 't/lib';
use Cpanel::JSON::XS ();
use MetaCPAN::TestHelpers;
use Test::More;

Expand All @@ -18,8 +18,8 @@ test_release(
'lib/local/lib.pm' => [
{
name => 'local::lib',
indexed => 'true',
authorized => 'true',
indexed => Cpanel::JSON::XS::true(),
authorized => Cpanel::JSON::XS::true(),
version => '0.01',
version_numified => 0.01,
associated_pod =>
Expand Down
4 changes: 1 addition & 3 deletions t/release/meta-provides.t
Expand Up @@ -2,10 +2,8 @@ use strict;
use warnings;

use MetaCPAN::Server::Test;
use Test::More;

use lib 't/lib';
use MetaCPAN::TestHelpers;
use Test::More;

test_release(
{
Expand Down
3 changes: 1 addition & 2 deletions t/release/no-modules.t
@@ -1,9 +1,8 @@
use Test::More;
use strict;
use warnings;

use lib 't/lib';
use MetaCPAN::TestHelpers;
use Test::More;

# Some uploads contain no usable modules.
test_release(
Expand Down
3 changes: 1 addition & 2 deletions t/release/no-packages.t
@@ -1,9 +1,8 @@
use Test::More;
use strict;
use warnings;

use lib 't/lib';
use MetaCPAN::TestHelpers;
use Test::More;

# Some uploads contain no usable modules.
test_release(
Expand Down
10 changes: 5 additions & 5 deletions t/release/oops-locallib.t
@@ -1,7 +1,7 @@
use strict;
use warnings;

use lib 't/lib';
use Cpanel::JSON::XS ();
use MetaCPAN::TestHelpers;
use Test::More;

Expand All @@ -17,8 +17,8 @@ test_release(
'lib/Oops/LocalLib.pm' => [
{
name => 'Oops::LocalLib',
indexed => 'true',
authorized => 'true',
indexed => Cpanel::JSON::XS::true(),
authorized => Cpanel::JSON::XS::true(),
version => '0.01',
version_numified => 0.01,
associated_pod =>
Expand All @@ -28,8 +28,8 @@ test_release(
'foreign/Fruits.pm' => [
{
name => 'Fruits',
indexed => 'true',
authorized => 'true',
indexed => Cpanel::JSON::XS::true(),
authorized => Cpanel::JSON::XS::true(),
version => '1',
version_numified => 1,
associated_pod =>
Expand Down
2 changes: 0 additions & 2 deletions t/release/p-1.0.20.t
@@ -1,8 +1,6 @@
use strict;
use warnings;

use lib 't/lib';

use MetaCPAN::TestHelpers qw( test_release );
use Ref::Util qw( is_hashref );
use Test::More;
Expand Down
5 changes: 3 additions & 2 deletions t/release/packages-unclaimable.t
@@ -1,6 +1,7 @@
use strict;
use warnings;

use Cpanel::JSON::XS ();
use IO::String;
use List::MoreUtils qw(uniq);
use MetaCPAN::Server::Test;
Expand All @@ -23,8 +24,8 @@ test_release(
'lib/Packages/Unclaimable.pm' => [
{
name => 'Packages::Unclaimable',
indexed => 'true',
authorized => 'true',
indexed => Cpanel::JSON::XS::true(),
authorized => Cpanel::JSON::XS::true(),
version => 2,
version_numified => 2,
associated_pod =>
Expand Down
9 changes: 5 additions & 4 deletions t/release/packages.t
@@ -1,6 +1,7 @@
use strict;
use warnings;

use Cpanel::JSON::XS ();
use MetaCPAN::Server::Test;
use MetaCPAN::TestHelpers;
use Test::More;
Expand All @@ -19,8 +20,8 @@ test_release(
'lib/Packages.pm' => [
{
name => 'Packages',
indexed => 'true',
authorized => 'true',
indexed => Cpanel::JSON::XS::true(),
authorized => Cpanel::JSON::XS::true(),
version => '1.103',
version_numified => 1.103,
associated_pod =>
Expand All @@ -30,8 +31,8 @@ test_release(
'lib/Packages/BOM.pm' => [
{
name => 'Packages::BOM',
indexed => 'true',
authorized => 'true',
indexed => Cpanel::JSON::XS::true(),
authorized => Cpanel::JSON::XS::true(),
version => 0.04,
version_numified => 0.04,
associated_pod =>
Expand Down
3 changes: 1 addition & 2 deletions t/release/pod-examples.t
@@ -1,10 +1,9 @@
use Test::More;
use strict;
use warnings;

use MetaCPAN::Server::Test;
use lib 't/lib';
use MetaCPAN::TestHelpers;
use Test::More;

test_release(
'RWSTAUNER/Pod-Examples-99',
Expand Down
6 changes: 3 additions & 3 deletions t/release/pod-with-data-token.t
@@ -1,7 +1,7 @@
use strict;
use warnings;

use lib 't/lib';
use Cpanel::JSON::XS ();
use MetaCPAN::TestHelpers;
use Test::More;

Expand All @@ -17,8 +17,8 @@ test_release(
'lib/Pod/With/Data/Token.pm' => [
{
name => 'Pod::With::Data::Token',
indexed => 'true',
authorized => 'true',
indexed => Cpanel::JSON::XS::true(),
authorized => Cpanel::JSON::XS::true(),
version => '0.01',
version_numified => 0.01,
associated_pod =>
Expand Down
6 changes: 3 additions & 3 deletions t/release/pod-with-generator.t
@@ -1,7 +1,7 @@
use strict;
use warnings;

use lib 't/lib';
use Cpanel::JSON::XS ();
use MetaCPAN::TestHelpers;
use Test::More;

Expand All @@ -17,8 +17,8 @@ test_release(
'lib/Pod/With/Generator.pm' => [
{
name => 'Pod::With::Generator',
indexed => 'true',
authorized => 'true',
indexed => Cpanel::JSON::XS::true(),
authorized => Cpanel::JSON::XS::true(),
version => '1',
version_numified => 1,
associated_pod =>
Expand Down
3 changes: 1 addition & 2 deletions t/release/text-tabs-wrap.t
@@ -1,9 +1,8 @@
use Test::More;
use strict;
use warnings;

use lib 't/lib';
use MetaCPAN::TestHelpers;
use Test::More;

test_distribution(
'Text-Tabs+Wrap',
Expand Down
3 changes: 1 addition & 2 deletions t/release/weblint++-1.15.t
@@ -1,9 +1,8 @@
use Test::More;
use strict;
use warnings;

use lib 't/lib';
use MetaCPAN::TestHelpers;
use Test::More;

test_release(
{
Expand Down

0 comments on commit 90014a1

Please sign in to comment.