Commit | Line | Data |
---|---|---|
3be1e192 | 1 | use strict; |
2 | use warnings FATAL => 'all'; | |
3 | use Test::Without::Module 'Cpanel::JSON::XS'; | |
4 | use if !do { require JSON::PP; 1; }, 'Test::More', skip_all => 'No JSON::PP'; | |
5 | use Test::More; | |
6 | use JSON::MaybeXS; | |
7 | ||
8 | is(JSON, 'JSON::PP', 'Correct JSON class'); | |
9 | ||
10 | is( | |
11 | \&encode_json, \&JSON::PP::encode_json, | |
12 | 'Correct encode_json function' | |
13 | ); | |
14 | ||
15 | is( | |
16 | \&decode_json, \&JSON::PP::decode_json, | |
17 | 'Correct encode_json function' | |
18 | ); | |
19 | ||
20 | done_testing; |