Skip to content
This repository has been archived by the owner on Apr 13, 2021. It is now read-only.

Commit

Permalink
Merge pull request #64 from techman83/fix_tests
Browse files Browse the repository at this point in the history
Fix tests
  • Loading branch information
techman83 committed May 6, 2018
2 parents 1742c70 + 4a2d5cf commit 36d4de9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
1 change: 1 addition & 0 deletions dist.ini
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ IO::Socket::SSL = 0
EV = 0
Twiggy = 0
LWP::Protocol::https = 0
JSON::XS = 0

[OurPkgVersion]
[PodWeaver]
Expand Down
8 changes: 7 additions & 1 deletion t/App/KSP_CKAN/Tools/NetKAN.t
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ TODO: {
isnt( $netkan->inflate, 0, "Return failure correctly" );

subtest 'Status Setting' => sub {
is($status->status->{'DogeCoinFlag-broken'}{last_error}, "JSON deserialization error", "'last_error' set on failure");
like($status->status->{'DogeCoinFlag-broken'}{last_error}, qr/^JSON deserialization error.+/, "'last_error' set on failure");
is($status->status->{'DogeCoinFlag-broken'}{failed}, 1, "'failed' true on failure");
is($status->status->{'DogeCoinFlag-broken'}{last_indexed}, undef, "'last_index' undef when no successful indexing has ever occured");
is($status->status->{'DogeCoinFlag'}{last_error}, undef, "'last_error' undef on success");
Expand Down Expand Up @@ -187,6 +187,12 @@ EOF
"Error wasn't parsable",
"Receive 'Error wasn't parsable' when none parsed"
);

is (
$netkan->_parse_error("2656 [1] FATAL CKAN.NetKAN.Program (null) - 303747d7-0830-4d.tmp is not a valid ZIP file: Error in step EntryHeader for Budget part cost set to 0.cfg: Exception during test - 'Compression method not supported'"),
"303747d7-0830-4d.tmp is not a valid ZIP file: Error in step EntryHeader for Budget part cost set to 0.cfg: Exception during test - 'Compression method not supported'",
".+ greediness fixed in regex - #63"
);
};

# Cleanup after ourselves
Expand Down

0 comments on commit 36d4de9

Please sign in to comment.