From 1e6eede7ca5c49be7bfc2978b11c74e1f284b8d8 Mon Sep 17 00:00:00 2001
From: mattab <matthieu.aubry@gmail.com>
Date: Mon, 17 Mar 2014 19:23:24 +1300
Subject: [PATCH] Tweaks to see if it helps the last build failure...

---
 tests/PHPUnit/Integration/ArchiveCronTest.php | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/tests/PHPUnit/Integration/ArchiveCronTest.php b/tests/PHPUnit/Integration/ArchiveCronTest.php
index dcc313d75c..1a835fd6d3 100644
--- a/tests/PHPUnit/Integration/ArchiveCronTest.php
+++ b/tests/PHPUnit/Integration/ArchiveCronTest.php
@@ -69,7 +69,7 @@ class Test_Piwik_Integration_ArchiveCronTest extends IntegrationTestCase
         // API Call Without segments
         $results[] = array('VisitsSummary.get', array('idSite'  => 'all',
                                                       'date'    => '2012-08-09',
-                                                      'periods' => array('day', 'week', 'month', 'year')));
+                                                      'periods' => array('day', 'month', 'year', 'week')));
 
         return $results;
     }
@@ -130,7 +130,7 @@ class Test_Piwik_Integration_ArchiveCronTest extends IntegrationTestCase
 
         // run the command
         exec($cmd, $output, $result);
-        if ($result !== 0) {
+        if ($result !== 0 || stripos($result, "error")) {
             throw new Exception("archive cron failed: " . implode("\n", $output) . "\n\ncommand used: $cmd");
         }
 
-- 
GitLab