summaryrefslogtreecommitdiff
path: root/t/Extract.t
diff options
context:
space:
mode:
authorJannis M. Hoffmann <jannis.hoffmann@rwth-aachen.de>2021-08-24 11:10:39 +0200
committerJannis M. Hoffmann <jannis.hoffmann@rwth-aachen.de>2021-08-24 11:10:39 +0200
commit2388747fbf954de990862a6c01713d50823e8725 (patch)
treec3b3a7dc80f1d6a978d25e3048f7a6afb9fa08e0 /t/Extract.t
parentbf5554febae6f299c716b5a9582c6bfd6980b728 (diff)
overhauled testing
Diffstat (limited to 't/Extract.t')
-rw-r--r--t/Extract.t6
1 files changed, 4 insertions, 2 deletions
diff --git a/t/Extract.t b/t/Extract.t
index 1d20d0f..5b719da 100644
--- a/t/Extract.t
+++ b/t/Extract.t
@@ -37,7 +37,6 @@ subtest folders => sub {
my $result = decode_json $res[0];
is(@$result, 2);
- ok($_ ~~ ['SUB.FOLDER', 'SENT']) for @$result;
};
subtest count => sub {
@@ -78,7 +77,10 @@ subtest read => sub {
is @res, 1;
my $result = decode_json $res[0];
- is($result->{from}, 'test');
+ is_deeply($result->{from}, [{address => 'shipment-tracking@amazon.de', name => 'Amazon.de'}]);
+ ok($result->{date_received});
+ ok(index($result->{date_received}, '2019-02-22T10:06:54') != -1);
+ like($result->{date_received}, qr'2019-02-22T10:06:54');
};
done_testing;