From ba9043e6a73aa3963bb6d1cd05df74be3b3856e0 Mon Sep 17 00:00:00 2001 From: Paul Beckingham Date: Mon, 10 Nov 2014 21:04:22 -0500 Subject: [PATCH] Unit Tests - Removed debugging output from test - that was not helping. - Added more basic tests because FreeBSD is misbehaving. --- test/roundtrip.t | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/test/roundtrip.t b/test/roundtrip.t index 459a9229c..99e0488d5 100755 --- a/test/roundtrip.t +++ b/test/roundtrip.t @@ -27,7 +27,7 @@ use strict; use warnings; -use Test::More tests => 3; +use Test::More tests => 5; # Ensure environment has no influence. delete $ENV{'TASKDATA'}; @@ -53,14 +53,16 @@ qx{../src/task rc:$rc add priority:H project:A -- one/1 2>&1}; qx{../src/task rc:$rc add +tag1 +tag2 two 2>&1}; # trip 1. -qx{../src/task rc:$rc export > ./roundtrip1.json 2>&1}; -unlink 'pending.data', 'completed.data', 'undo.data'; -qx{../src/task rc:$rc rc.debug:1 import ./roundtrip1.json 2>&1}; +qx{../src/task rc:$rc export > ./roundtrip1.json 2>/dev/null}; +ok (-s './roundtrip1.json' > 0, "$ut: roundtrip1.json is not empty"); +unlink 'pending.data', 'completed.data', 'undo.data', 'backlog.data'; +qx{../src/task rc:$rc import ./roundtrip1.json 2>/dev/null}; # trip 2. -qx{../src/task rc:$rc export > ./roundtrip2.json 2>&1}; -unlink 'pending.data', 'completed.data', 'undo.data'; -qx{../src/task rc:$rc import ./roundtrip2.json 2>&1}; +qx{../src/task rc:$rc export > ./roundtrip2.json 2>/dev/null}; +ok (-s './roundtrip2.json' > 0, "$ut: roundtrip2.json is not empty"); +unlink 'pending.data', 'completed.data', 'undo.data', 'backlog.data'; +qx{../src/task rc:$rc import ./roundtrip2.json 2>/dev/null}; # Examine. #