diff --git a/plugins/API/tests/RowEvolutionTest.php b/plugins/API/tests/Integration/RowEvolutionTest.php
similarity index 96%
rename from plugins/API/tests/RowEvolutionTest.php
rename to plugins/API/tests/Integration/RowEvolutionTest.php
index 21ea9224bd2133e283bc882ceb6517dbbd025e10..555921e56e209aaf24121f14769efb9a16a47d3d 100644
--- a/plugins/API/tests/RowEvolutionTest.php
+++ b/plugins/API/tests/Integration/RowEvolutionTest.php
@@ -6,7 +6,8 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\API\tests;
+namespace Piwik\Plugins\API\tests\Integration;
+
 use Piwik\Plugins\API\RowEvolution;
 use Piwik\Tests\Fixture;
 
diff --git a/plugins/API/tests/RssRendererTest.php b/plugins/API/tests/Integration/RssRendererTest.php
similarity index 99%
rename from plugins/API/tests/RssRendererTest.php
rename to plugins/API/tests/Integration/RssRendererTest.php
index 7187bae1d2d786b7a2d2323a89fdf952355e389b..8bc9fb0792c18e32b703d2191ccfc89181d93455 100644
--- a/plugins/API/tests/RssRendererTest.php
+++ b/plugins/API/tests/Integration/RssRendererTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\API\tests;
+namespace Piwik\Plugins\API\tests\Integration;
 
 use Piwik\Access;
 use Piwik\DataTable;
diff --git a/plugins/API/tests/ConsoleRendererTest.php b/plugins/API/tests/Unit/ConsoleRendererTest.php
similarity index 98%
rename from plugins/API/tests/ConsoleRendererTest.php
rename to plugins/API/tests/Unit/ConsoleRendererTest.php
index 26357935ff1e324fb5c32a04575a0a9dd249e571..bd556809ffc41971af1b88c83e458b56b4722b71 100644
--- a/plugins/API/tests/ConsoleRendererTest.php
+++ b/plugins/API/tests/Unit/ConsoleRendererTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\API\tests;
+namespace Piwik\Plugins\API\tests\Unit;
 
 use Piwik\DataTable;
 use Piwik\Plugins\API\Renderer\Console;
diff --git a/plugins/API/tests/CsvRendererTest.php b/plugins/API/tests/Unit/CsvRendererTest.php
similarity index 99%
rename from plugins/API/tests/CsvRendererTest.php
rename to plugins/API/tests/Unit/CsvRendererTest.php
index 526d2f3728ba2f5bbe3d608c227cdb2efa5511e1..76d16ed5154b8ebbefbf20c24728d28bc9649212 100644
--- a/plugins/API/tests/CsvRendererTest.php
+++ b/plugins/API/tests/Unit/CsvRendererTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\API\tests;
+namespace Piwik\Plugins\API\test\Unit;
 
 use Piwik\DataTable;
 use Piwik\Plugins\API\Renderer\Csv;
diff --git a/plugins/API/tests/HtmlRendererTest.php b/plugins/API/tests/Unit/HtmlRendererTest.php
similarity index 99%
rename from plugins/API/tests/HtmlRendererTest.php
rename to plugins/API/tests/Unit/HtmlRendererTest.php
index 4cf4f98c9b9f0f9ba15bb17c3846d225afd7f7e6..374f33e0b6ba6a3418c81ceb6a10c0a4b4179ccf 100644
--- a/plugins/API/tests/HtmlRendererTest.php
+++ b/plugins/API/tests/Unit/HtmlRendererTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\API\tests;
+namespace Piwik\Plugins\API\tests\Unit;
 
 use Piwik\DataTable;
 use Piwik\Plugins\API\Renderer\Html;
diff --git a/plugins/API/tests/JsonRendererTest.php b/plugins/API/tests/Unit/JsonRendererTest.php
similarity index 99%
rename from plugins/API/tests/JsonRendererTest.php
rename to plugins/API/tests/Unit/JsonRendererTest.php
index fc1bf5d5020e3969430cd83c76f8eef43ef03e41..c4fa076483ab5f82f6ba1190e671264782813885 100644
--- a/plugins/API/tests/JsonRendererTest.php
+++ b/plugins/API/tests/Unit/JsonRendererTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\API\tests;
+namespace Piwik\Plugins\API\tests\Unit;
 
 use Piwik\DataTable;
 use Piwik\Plugins\API\Renderer\Json;
diff --git a/plugins/API/tests/OriginalRendererTest.php b/plugins/API/tests/Unit/OriginalRendererTest.php
similarity index 99%
rename from plugins/API/tests/OriginalRendererTest.php
rename to plugins/API/tests/Unit/OriginalRendererTest.php
index 40a3575ec7c9ff2af350a7ea9cd1e8adf9bb21fd..bed40d1e29ce0bf9fb94da54e06b4ab6ceb8eaea 100644
Binary files a/plugins/API/tests/OriginalRendererTest.php and b/plugins/API/tests/Unit/OriginalRendererTest.php differ
diff --git a/plugins/API/tests/PhpRendererTest.php b/plugins/API/tests/Unit/PhpRendererTest.php
similarity index 99%
rename from plugins/API/tests/PhpRendererTest.php
rename to plugins/API/tests/Unit/PhpRendererTest.php
index 5234db8df158e07f674c45518ba83bd976416615..77a5efa5681b848a19597914531acf4e30072084 100644
--- a/plugins/API/tests/PhpRendererTest.php
+++ b/plugins/API/tests/Unit/PhpRendererTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\API\tests;
+namespace Piwik\Plugins\API\tests\Unit;
 
 use Piwik\DataTable;
 use Piwik\Plugins\API\Renderer\Php;
diff --git a/plugins/API/tests/XmlRendererTest.php b/plugins/API/tests/Unit/XmlRendererTest.php
similarity index 99%
rename from plugins/API/tests/XmlRendererTest.php
rename to plugins/API/tests/Unit/XmlRendererTest.php
index 1d222290bd0f4f250d3eba87e5d601dc6604a47b..f3ca71a10d2f9ceaedf0786fea13538945739bb3 100644
--- a/plugins/API/tests/XmlRendererTest.php
+++ b/plugins/API/tests/Unit/XmlRendererTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\API\tests;
+namespace Piwik\Plugins\API\tests\Unit;
 
 use Piwik\DataTable;
 use Piwik\Plugins\API\Renderer\Xml;
diff --git a/plugins/Actions/tests/ArchiverTest.php b/plugins/Actions/tests/Unit/ArchiverTest.php
similarity index 99%
rename from plugins/Actions/tests/ArchiverTest.php
rename to plugins/Actions/tests/Unit/ArchiverTest.php
index 6458f425fa457155db049f5802ecd6e34ce084e0..a3ba57511ab76e088de5741714d283c6f1e51d7c 100644
--- a/plugins/Actions/tests/ArchiverTest.php
+++ b/plugins/Actions/tests/Unit/ArchiverTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\PrivacyManager\tests;
+namespace Piwik\Plugins\PrivacyManager\tests\Unit;
 
 use Piwik\Plugins\Actions\ArchivingHelper;
 use Piwik\Tracker\Action;
diff --git a/plugins/Contents/.gitignore b/plugins/Contents/.gitignore
index b141f4501fd9f6d83093f837bc8c9f347b8edf31..c8c9480010db494b8cf54ca8f9561e7a14ff51ea 100644
--- a/plugins/Contents/.gitignore
+++ b/plugins/Contents/.gitignore
@@ -1 +1 @@
-tests/processed/*xml
\ No newline at end of file
+tests/System/processed/*xml
\ No newline at end of file
diff --git a/plugins/Contents/tests/ContentsTest.php b/plugins/Contents/tests/System/ContentsTest.php
similarity index 98%
rename from plugins/Contents/tests/ContentsTest.php
rename to plugins/Contents/tests/System/ContentsTest.php
index c07f491546809a9d6c9c17d5ef17a067db7bb084..d348133c2b9ef18fff1224f747b36d65793a7a6e 100644
--- a/plugins/Contents/tests/ContentsTest.php
+++ b/plugins/Contents/tests/System/ContentsTest.php
@@ -5,7 +5,7 @@
  * @link    http://piwik.org
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
-namespace Piwik\Plugins\Contents\tests;
+namespace Piwik\Plugins\Contents\tests\System;
 
 use Piwik\Tests\SystemTestCase;
 use Piwik\Plugins\Contents\tests\Fixtures\TwoVisitsWithContents;
diff --git a/plugins/Contents/tests/expected/test_Contents_Contents.getContentNames_lastN__API.getProcessedReport_day.xml b/plugins/Contents/tests/System/expected/test_Contents_Contents.getContentNames_lastN__API.getProcessedReport_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents_Contents.getContentNames_lastN__API.getProcessedReport_day.xml
rename to plugins/Contents/tests/System/expected/test_Contents_Contents.getContentNames_lastN__API.getProcessedReport_day.xml
diff --git a/plugins/Contents/tests/expected/test_Contents_Contents.getContentPieces_lastN__API.getProcessedReport_day.xml b/plugins/Contents/tests/System/expected/test_Contents_Contents.getContentPieces_lastN__API.getProcessedReport_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents_Contents.getContentPieces_lastN__API.getProcessedReport_day.xml
rename to plugins/Contents/tests/System/expected/test_Contents_Contents.getContentPieces_lastN__API.getProcessedReport_day.xml
diff --git a/plugins/Contents/tests/expected/test_Contents__Actions.getPageUrls_day.xml b/plugins/Contents/tests/System/expected/test_Contents__Actions.getPageUrls_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents__Actions.getPageUrls_day.xml
rename to plugins/Contents/tests/System/expected/test_Contents__Actions.getPageUrls_day.xml
diff --git a/plugins/Contents/tests/expected/test_Contents__Actions.getPageUrls_month.xml b/plugins/Contents/tests/System/expected/test_Contents__Actions.getPageUrls_month.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents__Actions.getPageUrls_month.xml
rename to plugins/Contents/tests/System/expected/test_Contents__Actions.getPageUrls_month.xml
diff --git a/plugins/Contents/tests/expected/test_Contents__Actions.get_day.xml b/plugins/Contents/tests/System/expected/test_Contents__Actions.get_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents__Actions.get_day.xml
rename to plugins/Contents/tests/System/expected/test_Contents__Actions.get_day.xml
diff --git a/plugins/Contents/tests/expected/test_Contents__Actions.get_month.xml b/plugins/Contents/tests/System/expected/test_Contents__Actions.get_month.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents__Actions.get_month.xml
rename to plugins/Contents/tests/System/expected/test_Contents__Actions.get_month.xml
diff --git a/plugins/Contents/tests/expected/test_Contents__Contents.getContentNames_day.xml b/plugins/Contents/tests/System/expected/test_Contents__Contents.getContentNames_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents__Contents.getContentNames_day.xml
rename to plugins/Contents/tests/System/expected/test_Contents__Contents.getContentNames_day.xml
diff --git a/plugins/Contents/tests/expected/test_Contents__Contents.getContentNames_month.xml b/plugins/Contents/tests/System/expected/test_Contents__Contents.getContentNames_month.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents__Contents.getContentNames_month.xml
rename to plugins/Contents/tests/System/expected/test_Contents__Contents.getContentNames_month.xml
diff --git a/plugins/Contents/tests/expected/test_Contents__Contents.getContentPieces_day.xml b/plugins/Contents/tests/System/expected/test_Contents__Contents.getContentPieces_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents__Contents.getContentPieces_day.xml
rename to plugins/Contents/tests/System/expected/test_Contents__Contents.getContentPieces_day.xml
diff --git a/plugins/Contents/tests/expected/test_Contents__Contents.getContentPieces_month.xml b/plugins/Contents/tests/System/expected/test_Contents__Contents.getContentPieces_month.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents__Contents.getContentPieces_month.xml
rename to plugins/Contents/tests/System/expected/test_Contents__Contents.getContentPieces_month.xml
diff --git a/plugins/Contents/tests/expected/test_Contents__Live.getLastVisitsDetails_day.xml b/plugins/Contents/tests/System/expected/test_Contents__Live.getLastVisitsDetails_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents__Live.getLastVisitsDetails_day.xml
rename to plugins/Contents/tests/System/expected/test_Contents__Live.getLastVisitsDetails_day.xml
diff --git a/plugins/Contents/tests/expected/test_Contents__Live.getLastVisitsDetails_month.xml b/plugins/Contents/tests/System/expected/test_Contents__Live.getLastVisitsDetails_month.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents__Live.getLastVisitsDetails_month.xml
rename to plugins/Contents/tests/System/expected/test_Contents__Live.getLastVisitsDetails_month.xml
diff --git a/plugins/Contents/tests/expected/test_Contents_contentInteractionMatch__Actions.getPageUrls_day.xml b/plugins/Contents/tests/System/expected/test_Contents_contentInteractionMatch__Actions.getPageUrls_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents_contentInteractionMatch__Actions.getPageUrls_day.xml
rename to plugins/Contents/tests/System/expected/test_Contents_contentInteractionMatch__Actions.getPageUrls_day.xml
diff --git a/plugins/Contents/tests/expected/test_Contents_contentInteractionMatch__Contents.getContentNames_day.xml b/plugins/Contents/tests/System/expected/test_Contents_contentInteractionMatch__Contents.getContentNames_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents_contentInteractionMatch__Contents.getContentNames_day.xml
rename to plugins/Contents/tests/System/expected/test_Contents_contentInteractionMatch__Contents.getContentNames_day.xml
diff --git a/plugins/Contents/tests/expected/test_Contents_contentInteractionMatch__Contents.getContentPieces_day.xml b/plugins/Contents/tests/System/expected/test_Contents_contentInteractionMatch__Contents.getContentPieces_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents_contentInteractionMatch__Contents.getContentPieces_day.xml
rename to plugins/Contents/tests/System/expected/test_Contents_contentInteractionMatch__Contents.getContentPieces_day.xml
diff --git a/plugins/Contents/tests/expected/test_Contents_contentInteractionMatch__Live.getLastVisitsDetails_day.xml b/plugins/Contents/tests/System/expected/test_Contents_contentInteractionMatch__Live.getLastVisitsDetails_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents_contentInteractionMatch__Live.getLastVisitsDetails_day.xml
rename to plugins/Contents/tests/System/expected/test_Contents_contentInteractionMatch__Live.getLastVisitsDetails_day.xml
diff --git a/plugins/Contents/tests/expected/test_Contents_contentTargetMatch__Actions.getPageUrls_day.xml b/plugins/Contents/tests/System/expected/test_Contents_contentTargetMatch__Actions.getPageUrls_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents_contentTargetMatch__Actions.getPageUrls_day.xml
rename to plugins/Contents/tests/System/expected/test_Contents_contentTargetMatch__Actions.getPageUrls_day.xml
diff --git a/plugins/Contents/tests/expected/test_Contents_contentTargetMatch__Contents.getContentNames_day.xml b/plugins/Contents/tests/System/expected/test_Contents_contentTargetMatch__Contents.getContentNames_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents_contentTargetMatch__Contents.getContentNames_day.xml
rename to plugins/Contents/tests/System/expected/test_Contents_contentTargetMatch__Contents.getContentNames_day.xml
diff --git a/plugins/Contents/tests/expected/test_Contents_contentTargetMatch__Contents.getContentPieces_day.xml b/plugins/Contents/tests/System/expected/test_Contents_contentTargetMatch__Contents.getContentPieces_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents_contentTargetMatch__Contents.getContentPieces_day.xml
rename to plugins/Contents/tests/System/expected/test_Contents_contentTargetMatch__Contents.getContentPieces_day.xml
diff --git a/plugins/Contents/tests/expected/test_Contents_contentTargetMatch__Live.getLastVisitsDetails_day.xml b/plugins/Contents/tests/System/expected/test_Contents_contentTargetMatch__Live.getLastVisitsDetails_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_Contents_contentTargetMatch__Live.getLastVisitsDetails_day.xml
rename to plugins/Contents/tests/System/expected/test_Contents_contentTargetMatch__Live.getLastVisitsDetails_day.xml
diff --git a/plugins/Contents/tests/expected/test_ContentscontentNameOrPieceMatch__Actions.getPageUrls_day.xml b/plugins/Contents/tests/System/expected/test_ContentscontentNameOrPieceMatch__Actions.getPageUrls_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_ContentscontentNameOrPieceMatch__Actions.getPageUrls_day.xml
rename to plugins/Contents/tests/System/expected/test_ContentscontentNameOrPieceMatch__Actions.getPageUrls_day.xml
diff --git a/plugins/Contents/tests/expected/test_ContentscontentNameOrPieceMatch__Contents.getContentNames_day.xml b/plugins/Contents/tests/System/expected/test_ContentscontentNameOrPieceMatch__Contents.getContentNames_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_ContentscontentNameOrPieceMatch__Contents.getContentNames_day.xml
rename to plugins/Contents/tests/System/expected/test_ContentscontentNameOrPieceMatch__Contents.getContentNames_day.xml
diff --git a/plugins/Contents/tests/expected/test_ContentscontentNameOrPieceMatch__Contents.getContentPieces_day.xml b/plugins/Contents/tests/System/expected/test_ContentscontentNameOrPieceMatch__Contents.getContentPieces_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_ContentscontentNameOrPieceMatch__Contents.getContentPieces_day.xml
rename to plugins/Contents/tests/System/expected/test_ContentscontentNameOrPieceMatch__Contents.getContentPieces_day.xml
diff --git a/plugins/Contents/tests/expected/test_ContentscontentNameOrPieceMatch__Live.getLastVisitsDetails_day.xml b/plugins/Contents/tests/System/expected/test_ContentscontentNameOrPieceMatch__Live.getLastVisitsDetails_day.xml
similarity index 100%
rename from plugins/Contents/tests/expected/test_ContentscontentNameOrPieceMatch__Live.getLastVisitsDetails_day.xml
rename to plugins/Contents/tests/System/expected/test_ContentscontentNameOrPieceMatch__Live.getLastVisitsDetails_day.xml
diff --git a/plugins/Contents/tests/processed/.gitkeep b/plugins/Contents/tests/System/processed/.gitkeep
similarity index 100%
rename from plugins/Contents/tests/processed/.gitkeep
rename to plugins/Contents/tests/System/processed/.gitkeep
diff --git a/plugins/Contents/tests/System/processed/test_Contents_Contents.getContentNames_lastN__API.getProcessedReport_day.xml b/plugins/Contents/tests/System/processed/test_Contents_Contents.getContentNames_lastN__API.getProcessedReport_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..d3e1af1e2edfb1ddd09905e52617e19448a000df
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents_Contents.getContentNames_lastN__API.getProcessedReport_day.xml
@@ -0,0 +1,83 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<website>Piwik test</website>
+	<prettyDate>3 Jan 10 - 9 Jan 10</prettyDate>
+	<metadata>
+		<category>Actions</category>
+		<name>Content Name</name>
+		<module>Contents</module>
+		<action>getContentNames</action>
+		<dimension>Content Name</dimension>
+		<metrics>
+			<nb_impressions>Impressions</nb_impressions>
+			<nb_interactions>Interactions</nb_interactions>
+		</metrics>
+		<processedMetrics>
+			<interaction_rate>Interaction Rate</interaction_rate>
+		</processedMetrics>
+		<actionToLoadSubTables>getContentNames</actionToLoadSubTables>
+		<imageGraphUrl>index.php?module=API&amp;method=ImageGraph.get&amp;idSite=1&amp;apiModule=Contents&amp;apiAction=getContentNames&amp;period=range&amp;date=2010-01-03,2010-01-09</imageGraphUrl>
+		<imageGraphEvolutionUrl>index.php?module=API&amp;method=ImageGraph.get&amp;idSite=1&amp;apiModule=Contents&amp;apiAction=getContentNames&amp;period=day&amp;date=2010-01-03,2010-01-09</imageGraphEvolutionUrl>
+		<uniqueId>Contents_getContentNames</uniqueId>
+	</metadata>
+	<columns>
+		<label>Content Name</label>
+		<nb_impressions>Impressions</nb_impressions>
+		<nb_interactions>Interactions</nb_interactions>
+		<interaction_rate>Interaction Rate</interaction_rate>
+	</columns>
+	<reportData>
+		<result prettyDate="Sunday 3 January 2010">
+			<row>
+				<label>ImageAd</label>
+				<nb_impressions>8</nb_impressions>
+				<nb_interactions>2</nb_interactions>
+				<interaction_rate>25%</interaction_rate>
+			</row>
+			<row>
+				<label>Text Ad</label>
+				<nb_impressions>6</nb_impressions>
+				<nb_interactions>4</nb_interactions>
+				<interaction_rate>66.67%</interaction_rate>
+			</row>
+			<row>
+				<label>Video Ad</label>
+				<nb_impressions>2</nb_impressions>
+				<nb_interactions>0</nb_interactions>
+				<interaction_rate>0%</interaction_rate>
+			</row>
+		</result>
+		<result prettyDate="Monday 4 January 2010" />
+		<result prettyDate="Tuesday 5 January 2010" />
+		<result prettyDate="Wednesday 6 January 2010" />
+		<result prettyDate="Thursday 7 January 2010" />
+		<result prettyDate="Friday 8 January 2010" />
+		<result prettyDate="Saturday 9 January 2010" />
+	</reportData>
+	<reportMetadata>
+		<result prettyDate="Sunday 3 January 2010">
+			<row>
+				<contentTarget>http://www.example.com</contentTarget>
+				
+			</row>
+			<row>
+				<contentTarget>http://piwik.org/</contentTarget>
+				
+			</row>
+			<row>
+				<contentTarget />
+				
+			</row>
+		</result>
+		<result prettyDate="Monday 4 January 2010" />
+		<result prettyDate="Tuesday 5 January 2010" />
+		<result prettyDate="Wednesday 6 January 2010" />
+		<result prettyDate="Thursday 7 January 2010" />
+		<result prettyDate="Friday 8 January 2010" />
+		<result prettyDate="Saturday 9 January 2010" />
+	</reportMetadata>
+	<reportTotal>
+		<nb_visits>16</nb_visits>
+		<nb_uniq_visitors>16</nb_uniq_visitors>
+	</reportTotal>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents_Contents.getContentPieces_lastN__API.getProcessedReport_day.xml b/plugins/Contents/tests/System/processed/test_Contents_Contents.getContentPieces_lastN__API.getProcessedReport_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..402909f7d5067b8e675eb06970effdeb67680842
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents_Contents.getContentPieces_lastN__API.getProcessedReport_day.xml
@@ -0,0 +1,123 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<website>Piwik test</website>
+	<prettyDate>3 Jan 10 - 9 Jan 10</prettyDate>
+	<metadata>
+		<category>Actions</category>
+		<name>Content Piece</name>
+		<module>Contents</module>
+		<action>getContentPieces</action>
+		<dimension>Content Piece</dimension>
+		<metrics>
+			<nb_impressions>Impressions</nb_impressions>
+			<nb_interactions>Interactions</nb_interactions>
+		</metrics>
+		<processedMetrics>
+			<interaction_rate>Interaction Rate</interaction_rate>
+		</processedMetrics>
+		<actionToLoadSubTables>getContentPieces</actionToLoadSubTables>
+		<imageGraphUrl>index.php?module=API&amp;method=ImageGraph.get&amp;idSite=1&amp;apiModule=Contents&amp;apiAction=getContentPieces&amp;period=range&amp;date=2010-01-03,2010-01-09</imageGraphUrl>
+		<imageGraphEvolutionUrl>index.php?module=API&amp;method=ImageGraph.get&amp;idSite=1&amp;apiModule=Contents&amp;apiAction=getContentPieces&amp;period=day&amp;date=2010-01-03,2010-01-09</imageGraphEvolutionUrl>
+		<uniqueId>Contents_getContentPieces</uniqueId>
+	</metadata>
+	<columns>
+		<label>Content Piece</label>
+		<nb_impressions>Impressions</nb_impressions>
+		<nb_interactions>Interactions</nb_interactions>
+		<interaction_rate>Interaction Rate</interaction_rate>
+	</columns>
+	<reportData>
+		<result prettyDate="Sunday 3 January 2010">
+			<row>
+				<label>Click to download Piwik now</label>
+				<nb_impressions>4</nb_impressions>
+				<nb_interactions>2</nb_interactions>
+				<interaction_rate>50%</interaction_rate>
+			</row>
+			<row>
+				<label>/path/ad.jpg</label>
+				<nb_impressions>2</nb_impressions>
+				<nb_interactions>2</nb_interactions>
+				<interaction_rate>100%</interaction_rate>
+			</row>
+			<row>
+				<label>/path/ad2.jpg</label>
+				<nb_impressions>2</nb_impressions>
+				<nb_interactions>0</nb_interactions>
+				<interaction_rate>0%</interaction_rate>
+			</row>
+			<row>
+				<label>Click NOW</label>
+				<nb_impressions>2</nb_impressions>
+				<nb_interactions>2</nb_interactions>
+				<interaction_rate>100%</interaction_rate>
+			</row>
+			<row>
+				<label>movie.mov</label>
+				<nb_impressions>2</nb_impressions>
+				<nb_interactions>0</nb_interactions>
+				<interaction_rate>0%</interaction_rate>
+			</row>
+			<row>
+				<label>Content Piece not defined</label>
+				<nb_impressions>2</nb_impressions>
+				<nb_interactions>0</nb_interactions>
+				<interaction_rate>0%</interaction_rate>
+			</row>
+			<row>
+				<label>Unknown</label>
+				<nb_impressions>2</nb_impressions>
+				<nb_interactions>0</nb_interactions>
+				<interaction_rate>0%</interaction_rate>
+			</row>
+		</result>
+		<result prettyDate="Monday 4 January 2010" />
+		<result prettyDate="Tuesday 5 January 2010" />
+		<result prettyDate="Wednesday 6 January 2010" />
+		<result prettyDate="Thursday 7 January 2010" />
+		<result prettyDate="Friday 8 January 2010" />
+		<result prettyDate="Saturday 9 January 2010" />
+	</reportData>
+	<reportMetadata>
+		<result prettyDate="Sunday 3 January 2010">
+			<row>
+				<contentTarget>http://piwik.org/download</contentTarget>
+				
+			</row>
+			<row>
+				<contentTarget>http://www.example.com</contentTarget>
+				
+			</row>
+			<row>
+				<contentTarget>http://www.example.com</contentTarget>
+				
+			</row>
+			<row>
+				<contentTarget>http://piwik.org/</contentTarget>
+				
+			</row>
+			<row>
+				<contentTarget />
+				
+			</row>
+			<row>
+				<contentTarget />
+				
+			</row>
+			<row>
+				<contentTarget />
+				
+			</row>
+		</result>
+		<result prettyDate="Monday 4 January 2010" />
+		<result prettyDate="Tuesday 5 January 2010" />
+		<result prettyDate="Wednesday 6 January 2010" />
+		<result prettyDate="Thursday 7 January 2010" />
+		<result prettyDate="Friday 8 January 2010" />
+		<result prettyDate="Saturday 9 January 2010" />
+	</reportMetadata>
+	<reportTotal>
+		<nb_visits>16</nb_visits>
+		<nb_uniq_visitors>16</nb_uniq_visitors>
+	</reportTotal>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents__Actions.getPageUrls_day.xml b/plugins/Contents/tests/System/processed/test_Contents__Actions.getPageUrls_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..fde347f2b53dc66196772a7ea0e6d522367e707d
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents__Actions.getPageUrls_day.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<label>/page</label>
+		<nb_visits>2</nb_visits>
+		<nb_uniq_visitors>2</nb_uniq_visitors>
+		<nb_hits>2</nb_hits>
+		<sum_time_spent>540</sum_time_spent>
+		<nb_hits_with_time_generation>2</nb_hits_with_time_generation>
+		<min_time_generation>0.333</min_time_generation>
+		<max_time_generation>0.333</max_time_generation>
+		<entry_nb_uniq_visitors>2</entry_nb_uniq_visitors>
+		<entry_nb_visits>2</entry_nb_visits>
+		<entry_nb_actions>2</entry_nb_actions>
+		<entry_sum_visit_length>542</entry_sum_visit_length>
+		<entry_bounce_count>2</entry_bounce_count>
+		<exit_nb_uniq_visitors>2</exit_nb_uniq_visitors>
+		<exit_nb_visits>2</exit_nb_visits>
+		<avg_time_on_page>270</avg_time_on_page>
+		<bounce_rate>100%</bounce_rate>
+		<exit_rate>100%</exit_rate>
+		<avg_time_generation>0.333</avg_time_generation>
+		<url>http://www.example.org/page</url>
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents__Actions.getPageUrls_month.xml b/plugins/Contents/tests/System/processed/test_Contents__Actions.getPageUrls_month.xml
new file mode 100644
index 0000000000000000000000000000000000000000..3dc775d40a8885e1c31b84093d990294ea6b06a2
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents__Actions.getPageUrls_month.xml
@@ -0,0 +1,25 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<label>/page</label>
+		<nb_visits>2</nb_visits>
+		<nb_hits>2</nb_hits>
+		<sum_time_spent>540</sum_time_spent>
+		<nb_hits_with_time_generation>2</nb_hits_with_time_generation>
+		<min_time_generation>0.333</min_time_generation>
+		<max_time_generation>0.333</max_time_generation>
+		<entry_nb_visits>2</entry_nb_visits>
+		<entry_nb_actions>2</entry_nb_actions>
+		<entry_sum_visit_length>542</entry_sum_visit_length>
+		<entry_bounce_count>2</entry_bounce_count>
+		<exit_nb_visits>2</exit_nb_visits>
+		<sum_daily_nb_uniq_visitors>2</sum_daily_nb_uniq_visitors>
+		<sum_daily_entry_nb_uniq_visitors>2</sum_daily_entry_nb_uniq_visitors>
+		<sum_daily_exit_nb_uniq_visitors>2</sum_daily_exit_nb_uniq_visitors>
+		<avg_time_on_page>270</avg_time_on_page>
+		<bounce_rate>100%</bounce_rate>
+		<exit_rate>100%</exit_rate>
+		<avg_time_generation>0.333</avg_time_generation>
+		<url>http://www.example.org/page</url>
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents__Actions.get_day.xml b/plugins/Contents/tests/System/processed/test_Contents__Actions.get_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..f51cfaf91365a6e9d5a96464ff4d0278a5d3a75a
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents__Actions.get_day.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<nb_pageviews>2</nb_pageviews>
+	<nb_uniq_pageviews>2</nb_uniq_pageviews>
+	<nb_downloads>0</nb_downloads>
+	<nb_uniq_downloads>0</nb_uniq_downloads>
+	<nb_outlinks>0</nb_outlinks>
+	<nb_uniq_outlinks>0</nb_uniq_outlinks>
+	<nb_searches>0</nb_searches>
+	<nb_keywords>0</nb_keywords>
+	<avg_time_generation>0.335</avg_time_generation>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents__Actions.get_month.xml b/plugins/Contents/tests/System/processed/test_Contents__Actions.get_month.xml
new file mode 100644
index 0000000000000000000000000000000000000000..f51cfaf91365a6e9d5a96464ff4d0278a5d3a75a
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents__Actions.get_month.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<nb_pageviews>2</nb_pageviews>
+	<nb_uniq_pageviews>2</nb_uniq_pageviews>
+	<nb_downloads>0</nb_downloads>
+	<nb_uniq_downloads>0</nb_uniq_downloads>
+	<nb_outlinks>0</nb_outlinks>
+	<nb_uniq_outlinks>0</nb_uniq_outlinks>
+	<nb_searches>0</nb_searches>
+	<nb_keywords>0</nb_keywords>
+	<avg_time_generation>0.335</avg_time_generation>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents__Contents.getContentNames_day.xml b/plugins/Contents/tests/System/processed/test_Contents__Contents.getContentNames_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..957c6fa85a64866f6b237520ec60478ee7413615
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents__Contents.getContentNames_day.xml
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<label>ImageAd</label>
+		<nb_uniq_visitors>8</nb_uniq_visitors>
+		<nb_visits>8</nb_visits>
+		<nb_impressions>8</nb_impressions>
+		<nb_interactions>2</nb_interactions>
+		<interaction_rate>25%</interaction_rate>
+		<contentTarget>http://www.example.com</contentTarget>
+	</row>
+	<row>
+		<label>Text Ad</label>
+		<nb_uniq_visitors>6</nb_uniq_visitors>
+		<nb_visits>6</nb_visits>
+		<nb_impressions>6</nb_impressions>
+		<nb_interactions>4</nb_interactions>
+		<interaction_rate>66.67%</interaction_rate>
+		<contentTarget>http://piwik.org/</contentTarget>
+	</row>
+	<row>
+		<label>Video Ad</label>
+		<nb_uniq_visitors>2</nb_uniq_visitors>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>0</nb_interactions>
+		<interaction_rate>0%</interaction_rate>
+		<contentTarget />
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents__Contents.getContentNames_month.xml b/plugins/Contents/tests/System/processed/test_Contents__Contents.getContentNames_month.xml
new file mode 100644
index 0000000000000000000000000000000000000000..44bfdfd54e4cd19a18f5ea445504439831a95040
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents__Contents.getContentNames_month.xml
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<label>ImageAd</label>
+		<nb_visits>8</nb_visits>
+		<nb_impressions>8</nb_impressions>
+		<nb_interactions>2</nb_interactions>
+		<sum_daily_nb_uniq_visitors>8</sum_daily_nb_uniq_visitors>
+		<interaction_rate>25%</interaction_rate>
+		<contentTarget>http://www.example.com</contentTarget>
+	</row>
+	<row>
+		<label>Text Ad</label>
+		<nb_visits>6</nb_visits>
+		<nb_impressions>6</nb_impressions>
+		<nb_interactions>4</nb_interactions>
+		<sum_daily_nb_uniq_visitors>6</sum_daily_nb_uniq_visitors>
+		<interaction_rate>66.67%</interaction_rate>
+		<contentTarget>http://piwik.org/</contentTarget>
+	</row>
+	<row>
+		<label>Video Ad</label>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>0</nb_interactions>
+		<sum_daily_nb_uniq_visitors>2</sum_daily_nb_uniq_visitors>
+		<interaction_rate>0%</interaction_rate>
+		<contentTarget />
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents__Contents.getContentPieces_day.xml b/plugins/Contents/tests/System/processed/test_Contents__Contents.getContentPieces_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..8927f8a8ece1b1d446fd2e843f69699c5921261a
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents__Contents.getContentPieces_day.xml
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<label>Click to download Piwik now</label>
+		<nb_uniq_visitors>4</nb_uniq_visitors>
+		<nb_visits>4</nb_visits>
+		<nb_impressions>4</nb_impressions>
+		<nb_interactions>2</nb_interactions>
+		<interaction_rate>50%</interaction_rate>
+		<contentTarget>http://piwik.org/download</contentTarget>
+	</row>
+	<row>
+		<label>/path/ad.jpg</label>
+		<nb_uniq_visitors>2</nb_uniq_visitors>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>2</nb_interactions>
+		<interaction_rate>100%</interaction_rate>
+		<contentTarget>http://www.example.com</contentTarget>
+	</row>
+	<row>
+		<label>/path/ad2.jpg</label>
+		<nb_uniq_visitors>2</nb_uniq_visitors>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>0</nb_interactions>
+		<interaction_rate>0%</interaction_rate>
+		<contentTarget>http://www.example.com</contentTarget>
+	</row>
+	<row>
+		<label>Click NOW</label>
+		<nb_uniq_visitors>2</nb_uniq_visitors>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>2</nb_interactions>
+		<interaction_rate>100%</interaction_rate>
+		<contentTarget>http://piwik.org/</contentTarget>
+	</row>
+	<row>
+		<label>movie.mov</label>
+		<nb_uniq_visitors>2</nb_uniq_visitors>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>0</nb_interactions>
+		<interaction_rate>0%</interaction_rate>
+		<contentTarget />
+	</row>
+	<row>
+		<label>Content Piece not defined</label>
+		<nb_uniq_visitors>2</nb_uniq_visitors>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>0</nb_interactions>
+		<interaction_rate>0%</interaction_rate>
+		<contentTarget />
+	</row>
+	<row>
+		<label>Unknown</label>
+		<nb_uniq_visitors>2</nb_uniq_visitors>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>0</nb_interactions>
+		<interaction_rate>0%</interaction_rate>
+		<contentTarget />
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents__Contents.getContentPieces_month.xml b/plugins/Contents/tests/System/processed/test_Contents__Contents.getContentPieces_month.xml
new file mode 100644
index 0000000000000000000000000000000000000000..b6045444175ecf06d87eba7d31d7e13834af0e3b
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents__Contents.getContentPieces_month.xml
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<label>Click to download Piwik now</label>
+		<nb_visits>4</nb_visits>
+		<nb_impressions>4</nb_impressions>
+		<nb_interactions>2</nb_interactions>
+		<sum_daily_nb_uniq_visitors>4</sum_daily_nb_uniq_visitors>
+		<interaction_rate>50%</interaction_rate>
+		<contentTarget>http://piwik.org/download</contentTarget>
+	</row>
+	<row>
+		<label>/path/ad.jpg</label>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>2</nb_interactions>
+		<sum_daily_nb_uniq_visitors>2</sum_daily_nb_uniq_visitors>
+		<interaction_rate>100%</interaction_rate>
+		<contentTarget>http://www.example.com</contentTarget>
+	</row>
+	<row>
+		<label>/path/ad2.jpg</label>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>0</nb_interactions>
+		<sum_daily_nb_uniq_visitors>2</sum_daily_nb_uniq_visitors>
+		<interaction_rate>0%</interaction_rate>
+		<contentTarget>http://www.example.com</contentTarget>
+	</row>
+	<row>
+		<label>Click NOW</label>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>2</nb_interactions>
+		<sum_daily_nb_uniq_visitors>2</sum_daily_nb_uniq_visitors>
+		<interaction_rate>100%</interaction_rate>
+		<contentTarget>http://piwik.org/</contentTarget>
+	</row>
+	<row>
+		<label>movie.mov</label>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>0</nb_interactions>
+		<sum_daily_nb_uniq_visitors>2</sum_daily_nb_uniq_visitors>
+		<interaction_rate>0%</interaction_rate>
+		<contentTarget />
+	</row>
+	<row>
+		<label>Content Piece not defined</label>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>0</nb_interactions>
+		<sum_daily_nb_uniq_visitors>2</sum_daily_nb_uniq_visitors>
+		<interaction_rate>0%</interaction_rate>
+		<contentTarget />
+	</row>
+	<row>
+		<label>Unknown</label>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>0</nb_interactions>
+		<sum_daily_nb_uniq_visitors>2</sum_daily_nb_uniq_visitors>
+		<interaction_rate>0%</interaction_rate>
+		<contentTarget />
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents__Live.getLastVisitsDetails_day.xml b/plugins/Contents/tests/System/processed/test_Contents__Live.getLastVisitsDetails_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..989f816722569544d52920872adc903958cc58b6
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents__Live.getLastVisitsDetails_day.xml
@@ -0,0 +1,199 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<idSite>1</idSite>
+		<idVisit>1</idVisit>
+		<visitIp>156.5.3.2</visitIp>
+		
+		<actionDetails>
+			<row>
+				<type>action</type>
+				<url>http://www.example.org/page</url>
+				<pageTitle>Ads</pageTitle>
+				<pageIdAction>2</pageIdAction>
+				
+				<pageId>1</pageId>
+				<generationTime>0.33s</generationTime>
+				<timeSpent>0</timeSpent>
+				<timeSpentPretty>0s</timeSpentPretty>
+				<icon />
+			</row>
+		</actionDetails>
+		<goalConversions>0</goalConversions>
+		<siteCurrency>USD</siteCurrency>
+		<siteCurrencySymbol>$</siteCurrencySymbol>
+		
+		
+		
+		
+		<searches>0</searches>
+		<actions>1</actions>
+		<userId />
+		<visitorType>new</visitorType>
+		<visitorTypeIcon />
+		<visitConverted>0</visitConverted>
+		<visitConvertedIcon />
+		<visitCount>1</visitCount>
+		
+		<visitEcommerceStatus>none</visitEcommerceStatus>
+		<visitEcommerceStatusIcon />
+		<daysSinceFirstVisit>0</daysSinceFirstVisit>
+		<daysSinceLastEcommerceOrder>0</daysSinceLastEcommerceOrder>
+		<visitDuration>271</visitDuration>
+		<visitDurationPretty>4 min 31s</visitDurationPretty>
+		<customVariables>
+		</customVariables>
+		<deviceType>Desktop</deviceType>
+		<events>0</events>
+		<provider>Unknown</provider>
+		<providerName>Unknown</providerName>
+		<providerUrl>http://piwik.org/faq/general/#faq_52</providerUrl>
+		<referrerType>direct</referrerType>
+		<referrerTypeName>Direct Entry</referrerTypeName>
+		<referrerName />
+		<referrerKeyword />
+		<referrerKeywordPosition />
+		<referrerUrl />
+		<referrerSearchEngineUrl />
+		<referrerSearchEngineIcon />
+		<continent>Europe</continent>
+		<continentCode>eur</continentCode>
+		<country>France</country>
+		<countryCode>fr</countryCode>
+		<countryFlag>plugins/UserCountry/images/flags/fr.png</countryFlag>
+		<region />
+		<regionCode />
+		<city />
+		<location>France</location>
+		<latitude />
+		<longitude />
+		<operatingSystem>Windows XP</operatingSystem>
+		<operatingSystemCode>WXP</operatingSystemCode>
+		<operatingSystemShortName>Win XP</operatingSystemShortName>
+		<operatingSystemIcon>plugins/UserSettings/images/os/WXP.gif</operatingSystemIcon>
+		<browserFamily>gecko</browserFamily>
+		<browserFamilyDescription>Gecko (Firefox)</browserFamilyDescription>
+		<browserName>Firefox 3.6</browserName>
+		<browserIcon>plugins/UserSettings/images/browsers/FF.gif</browserIcon>
+		<browserCode>FF</browserCode>
+		<browserVersion>3.6</browserVersion>
+		<screenType>normal</screenType>
+		<resolution>1024x768</resolution>
+		<screenTypeIcon>plugins/UserSettings/images/screens/normal.gif</screenTypeIcon>
+		<plugins>flash, java</plugins>
+		<pluginsIcons>
+			<row>
+				<pluginIcon>plugins/UserSettings/images/plugins/flash.gif</pluginIcon>
+				<pluginName>flash</pluginName>
+			</row>
+			<row>
+				<pluginIcon>plugins/UserSettings/images/plugins/java.gif</pluginIcon>
+				<pluginName>java</pluginName>
+			</row>
+		</pluginsIcons>
+		<visitLocalTime>12:34:06</visitLocalTime>
+		<visitLocalHour>12</visitLocalHour>
+		<daysSinceLastVisit>0</daysSinceLastVisit>
+		
+		
+		
+		
+		
+	</row>
+	<row>
+		<idSite>1</idSite>
+		<idVisit>2</idVisit>
+		<visitIp>111.1.1.1</visitIp>
+		
+		<actionDetails>
+			<row>
+				<type>action</type>
+				<url>http://www.example.org/page</url>
+				<pageTitle>Ads</pageTitle>
+				<pageIdAction>2</pageIdAction>
+				
+				<pageId>13</pageId>
+				<generationTime>0.33s</generationTime>
+				<timeSpent>0</timeSpent>
+				<timeSpentPretty>0s</timeSpentPretty>
+				<icon />
+			</row>
+		</actionDetails>
+		<goalConversions>0</goalConversions>
+		<siteCurrency>USD</siteCurrency>
+		<siteCurrencySymbol>$</siteCurrencySymbol>
+		
+		
+		
+		
+		<searches>0</searches>
+		<actions>1</actions>
+		<userId />
+		<visitorType>new</visitorType>
+		<visitorTypeIcon />
+		<visitConverted>0</visitConverted>
+		<visitConvertedIcon />
+		<visitCount>1</visitCount>
+		
+		<visitEcommerceStatus>none</visitEcommerceStatus>
+		<visitEcommerceStatusIcon />
+		<daysSinceFirstVisit>0</daysSinceFirstVisit>
+		<daysSinceLastEcommerceOrder>0</daysSinceLastEcommerceOrder>
+		<visitDuration>271</visitDuration>
+		<visitDurationPretty>4 min 31s</visitDurationPretty>
+		<customVariables>
+		</customVariables>
+		<deviceType>Desktop</deviceType>
+		<events>0</events>
+		<provider>Unknown</provider>
+		<providerName>Unknown</providerName>
+		<providerUrl>http://piwik.org/faq/general/#faq_52</providerUrl>
+		<referrerType>direct</referrerType>
+		<referrerTypeName>Direct Entry</referrerTypeName>
+		<referrerName />
+		<referrerKeyword />
+		<referrerKeywordPosition />
+		<referrerUrl />
+		<referrerSearchEngineUrl />
+		<referrerSearchEngineIcon />
+		<continent>Europe</continent>
+		<continentCode>eur</continentCode>
+		<country>France</country>
+		<countryCode>fr</countryCode>
+		<countryFlag>plugins/UserCountry/images/flags/fr.png</countryFlag>
+		<region />
+		<regionCode />
+		<city />
+		<location>France</location>
+		<latitude />
+		<longitude />
+		<operatingSystem>Windows XP</operatingSystem>
+		<operatingSystemCode>WXP</operatingSystemCode>
+		<operatingSystemShortName>Win XP</operatingSystemShortName>
+		<operatingSystemIcon>plugins/UserSettings/images/os/WXP.gif</operatingSystemIcon>
+		<browserFamily>gecko</browserFamily>
+		<browserFamilyDescription>Gecko (Firefox)</browserFamilyDescription>
+		<browserName>Firefox 3.6</browserName>
+		<browserIcon>plugins/UserSettings/images/browsers/FF.gif</browserIcon>
+		<browserCode>FF</browserCode>
+		<browserVersion>3.6</browserVersion>
+		<screenType>normal</screenType>
+		<resolution>1024x768</resolution>
+		<screenTypeIcon>plugins/UserSettings/images/screens/normal.gif</screenTypeIcon>
+		<plugins>director</plugins>
+		<pluginsIcons>
+			<row>
+				<pluginIcon>plugins/UserSettings/images/plugins/director.gif</pluginIcon>
+				<pluginName>director</pluginName>
+			</row>
+		</pluginsIcons>
+		<visitLocalTime>12:34:06</visitLocalTime>
+		<visitLocalHour>12</visitLocalHour>
+		<daysSinceLastVisit>0</daysSinceLastVisit>
+		
+		
+		
+		
+		
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents__Live.getLastVisitsDetails_month.xml b/plugins/Contents/tests/System/processed/test_Contents__Live.getLastVisitsDetails_month.xml
new file mode 100644
index 0000000000000000000000000000000000000000..989f816722569544d52920872adc903958cc58b6
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents__Live.getLastVisitsDetails_month.xml
@@ -0,0 +1,199 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<idSite>1</idSite>
+		<idVisit>1</idVisit>
+		<visitIp>156.5.3.2</visitIp>
+		
+		<actionDetails>
+			<row>
+				<type>action</type>
+				<url>http://www.example.org/page</url>
+				<pageTitle>Ads</pageTitle>
+				<pageIdAction>2</pageIdAction>
+				
+				<pageId>1</pageId>
+				<generationTime>0.33s</generationTime>
+				<timeSpent>0</timeSpent>
+				<timeSpentPretty>0s</timeSpentPretty>
+				<icon />
+			</row>
+		</actionDetails>
+		<goalConversions>0</goalConversions>
+		<siteCurrency>USD</siteCurrency>
+		<siteCurrencySymbol>$</siteCurrencySymbol>
+		
+		
+		
+		
+		<searches>0</searches>
+		<actions>1</actions>
+		<userId />
+		<visitorType>new</visitorType>
+		<visitorTypeIcon />
+		<visitConverted>0</visitConverted>
+		<visitConvertedIcon />
+		<visitCount>1</visitCount>
+		
+		<visitEcommerceStatus>none</visitEcommerceStatus>
+		<visitEcommerceStatusIcon />
+		<daysSinceFirstVisit>0</daysSinceFirstVisit>
+		<daysSinceLastEcommerceOrder>0</daysSinceLastEcommerceOrder>
+		<visitDuration>271</visitDuration>
+		<visitDurationPretty>4 min 31s</visitDurationPretty>
+		<customVariables>
+		</customVariables>
+		<deviceType>Desktop</deviceType>
+		<events>0</events>
+		<provider>Unknown</provider>
+		<providerName>Unknown</providerName>
+		<providerUrl>http://piwik.org/faq/general/#faq_52</providerUrl>
+		<referrerType>direct</referrerType>
+		<referrerTypeName>Direct Entry</referrerTypeName>
+		<referrerName />
+		<referrerKeyword />
+		<referrerKeywordPosition />
+		<referrerUrl />
+		<referrerSearchEngineUrl />
+		<referrerSearchEngineIcon />
+		<continent>Europe</continent>
+		<continentCode>eur</continentCode>
+		<country>France</country>
+		<countryCode>fr</countryCode>
+		<countryFlag>plugins/UserCountry/images/flags/fr.png</countryFlag>
+		<region />
+		<regionCode />
+		<city />
+		<location>France</location>
+		<latitude />
+		<longitude />
+		<operatingSystem>Windows XP</operatingSystem>
+		<operatingSystemCode>WXP</operatingSystemCode>
+		<operatingSystemShortName>Win XP</operatingSystemShortName>
+		<operatingSystemIcon>plugins/UserSettings/images/os/WXP.gif</operatingSystemIcon>
+		<browserFamily>gecko</browserFamily>
+		<browserFamilyDescription>Gecko (Firefox)</browserFamilyDescription>
+		<browserName>Firefox 3.6</browserName>
+		<browserIcon>plugins/UserSettings/images/browsers/FF.gif</browserIcon>
+		<browserCode>FF</browserCode>
+		<browserVersion>3.6</browserVersion>
+		<screenType>normal</screenType>
+		<resolution>1024x768</resolution>
+		<screenTypeIcon>plugins/UserSettings/images/screens/normal.gif</screenTypeIcon>
+		<plugins>flash, java</plugins>
+		<pluginsIcons>
+			<row>
+				<pluginIcon>plugins/UserSettings/images/plugins/flash.gif</pluginIcon>
+				<pluginName>flash</pluginName>
+			</row>
+			<row>
+				<pluginIcon>plugins/UserSettings/images/plugins/java.gif</pluginIcon>
+				<pluginName>java</pluginName>
+			</row>
+		</pluginsIcons>
+		<visitLocalTime>12:34:06</visitLocalTime>
+		<visitLocalHour>12</visitLocalHour>
+		<daysSinceLastVisit>0</daysSinceLastVisit>
+		
+		
+		
+		
+		
+	</row>
+	<row>
+		<idSite>1</idSite>
+		<idVisit>2</idVisit>
+		<visitIp>111.1.1.1</visitIp>
+		
+		<actionDetails>
+			<row>
+				<type>action</type>
+				<url>http://www.example.org/page</url>
+				<pageTitle>Ads</pageTitle>
+				<pageIdAction>2</pageIdAction>
+				
+				<pageId>13</pageId>
+				<generationTime>0.33s</generationTime>
+				<timeSpent>0</timeSpent>
+				<timeSpentPretty>0s</timeSpentPretty>
+				<icon />
+			</row>
+		</actionDetails>
+		<goalConversions>0</goalConversions>
+		<siteCurrency>USD</siteCurrency>
+		<siteCurrencySymbol>$</siteCurrencySymbol>
+		
+		
+		
+		
+		<searches>0</searches>
+		<actions>1</actions>
+		<userId />
+		<visitorType>new</visitorType>
+		<visitorTypeIcon />
+		<visitConverted>0</visitConverted>
+		<visitConvertedIcon />
+		<visitCount>1</visitCount>
+		
+		<visitEcommerceStatus>none</visitEcommerceStatus>
+		<visitEcommerceStatusIcon />
+		<daysSinceFirstVisit>0</daysSinceFirstVisit>
+		<daysSinceLastEcommerceOrder>0</daysSinceLastEcommerceOrder>
+		<visitDuration>271</visitDuration>
+		<visitDurationPretty>4 min 31s</visitDurationPretty>
+		<customVariables>
+		</customVariables>
+		<deviceType>Desktop</deviceType>
+		<events>0</events>
+		<provider>Unknown</provider>
+		<providerName>Unknown</providerName>
+		<providerUrl>http://piwik.org/faq/general/#faq_52</providerUrl>
+		<referrerType>direct</referrerType>
+		<referrerTypeName>Direct Entry</referrerTypeName>
+		<referrerName />
+		<referrerKeyword />
+		<referrerKeywordPosition />
+		<referrerUrl />
+		<referrerSearchEngineUrl />
+		<referrerSearchEngineIcon />
+		<continent>Europe</continent>
+		<continentCode>eur</continentCode>
+		<country>France</country>
+		<countryCode>fr</countryCode>
+		<countryFlag>plugins/UserCountry/images/flags/fr.png</countryFlag>
+		<region />
+		<regionCode />
+		<city />
+		<location>France</location>
+		<latitude />
+		<longitude />
+		<operatingSystem>Windows XP</operatingSystem>
+		<operatingSystemCode>WXP</operatingSystemCode>
+		<operatingSystemShortName>Win XP</operatingSystemShortName>
+		<operatingSystemIcon>plugins/UserSettings/images/os/WXP.gif</operatingSystemIcon>
+		<browserFamily>gecko</browserFamily>
+		<browserFamilyDescription>Gecko (Firefox)</browserFamilyDescription>
+		<browserName>Firefox 3.6</browserName>
+		<browserIcon>plugins/UserSettings/images/browsers/FF.gif</browserIcon>
+		<browserCode>FF</browserCode>
+		<browserVersion>3.6</browserVersion>
+		<screenType>normal</screenType>
+		<resolution>1024x768</resolution>
+		<screenTypeIcon>plugins/UserSettings/images/screens/normal.gif</screenTypeIcon>
+		<plugins>director</plugins>
+		<pluginsIcons>
+			<row>
+				<pluginIcon>plugins/UserSettings/images/plugins/director.gif</pluginIcon>
+				<pluginName>director</pluginName>
+			</row>
+		</pluginsIcons>
+		<visitLocalTime>12:34:06</visitLocalTime>
+		<visitLocalHour>12</visitLocalHour>
+		<daysSinceLastVisit>0</daysSinceLastVisit>
+		
+		
+		
+		
+		
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents_contentInteractionMatch__Actions.getPageUrls_day.xml b/plugins/Contents/tests/System/processed/test_Contents_contentInteractionMatch__Actions.getPageUrls_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..c234bed59e963e268d7a9bc05348d941758c4aa9
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents_contentInteractionMatch__Actions.getPageUrls_day.xml
@@ -0,0 +1,2 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result />
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents_contentInteractionMatch__Contents.getContentNames_day.xml b/plugins/Contents/tests/System/processed/test_Contents_contentInteractionMatch__Contents.getContentNames_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..c234bed59e963e268d7a9bc05348d941758c4aa9
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents_contentInteractionMatch__Contents.getContentNames_day.xml
@@ -0,0 +1,2 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result />
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents_contentInteractionMatch__Contents.getContentPieces_day.xml b/plugins/Contents/tests/System/processed/test_Contents_contentInteractionMatch__Contents.getContentPieces_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..c234bed59e963e268d7a9bc05348d941758c4aa9
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents_contentInteractionMatch__Contents.getContentPieces_day.xml
@@ -0,0 +1,2 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result />
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents_contentInteractionMatch__Live.getLastVisitsDetails_day.xml b/plugins/Contents/tests/System/processed/test_Contents_contentInteractionMatch__Live.getLastVisitsDetails_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..989f816722569544d52920872adc903958cc58b6
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents_contentInteractionMatch__Live.getLastVisitsDetails_day.xml
@@ -0,0 +1,199 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<idSite>1</idSite>
+		<idVisit>1</idVisit>
+		<visitIp>156.5.3.2</visitIp>
+		
+		<actionDetails>
+			<row>
+				<type>action</type>
+				<url>http://www.example.org/page</url>
+				<pageTitle>Ads</pageTitle>
+				<pageIdAction>2</pageIdAction>
+				
+				<pageId>1</pageId>
+				<generationTime>0.33s</generationTime>
+				<timeSpent>0</timeSpent>
+				<timeSpentPretty>0s</timeSpentPretty>
+				<icon />
+			</row>
+		</actionDetails>
+		<goalConversions>0</goalConversions>
+		<siteCurrency>USD</siteCurrency>
+		<siteCurrencySymbol>$</siteCurrencySymbol>
+		
+		
+		
+		
+		<searches>0</searches>
+		<actions>1</actions>
+		<userId />
+		<visitorType>new</visitorType>
+		<visitorTypeIcon />
+		<visitConverted>0</visitConverted>
+		<visitConvertedIcon />
+		<visitCount>1</visitCount>
+		
+		<visitEcommerceStatus>none</visitEcommerceStatus>
+		<visitEcommerceStatusIcon />
+		<daysSinceFirstVisit>0</daysSinceFirstVisit>
+		<daysSinceLastEcommerceOrder>0</daysSinceLastEcommerceOrder>
+		<visitDuration>271</visitDuration>
+		<visitDurationPretty>4 min 31s</visitDurationPretty>
+		<customVariables>
+		</customVariables>
+		<deviceType>Desktop</deviceType>
+		<events>0</events>
+		<provider>Unknown</provider>
+		<providerName>Unknown</providerName>
+		<providerUrl>http://piwik.org/faq/general/#faq_52</providerUrl>
+		<referrerType>direct</referrerType>
+		<referrerTypeName>Direct Entry</referrerTypeName>
+		<referrerName />
+		<referrerKeyword />
+		<referrerKeywordPosition />
+		<referrerUrl />
+		<referrerSearchEngineUrl />
+		<referrerSearchEngineIcon />
+		<continent>Europe</continent>
+		<continentCode>eur</continentCode>
+		<country>France</country>
+		<countryCode>fr</countryCode>
+		<countryFlag>plugins/UserCountry/images/flags/fr.png</countryFlag>
+		<region />
+		<regionCode />
+		<city />
+		<location>France</location>
+		<latitude />
+		<longitude />
+		<operatingSystem>Windows XP</operatingSystem>
+		<operatingSystemCode>WXP</operatingSystemCode>
+		<operatingSystemShortName>Win XP</operatingSystemShortName>
+		<operatingSystemIcon>plugins/UserSettings/images/os/WXP.gif</operatingSystemIcon>
+		<browserFamily>gecko</browserFamily>
+		<browserFamilyDescription>Gecko (Firefox)</browserFamilyDescription>
+		<browserName>Firefox 3.6</browserName>
+		<browserIcon>plugins/UserSettings/images/browsers/FF.gif</browserIcon>
+		<browserCode>FF</browserCode>
+		<browserVersion>3.6</browserVersion>
+		<screenType>normal</screenType>
+		<resolution>1024x768</resolution>
+		<screenTypeIcon>plugins/UserSettings/images/screens/normal.gif</screenTypeIcon>
+		<plugins>flash, java</plugins>
+		<pluginsIcons>
+			<row>
+				<pluginIcon>plugins/UserSettings/images/plugins/flash.gif</pluginIcon>
+				<pluginName>flash</pluginName>
+			</row>
+			<row>
+				<pluginIcon>plugins/UserSettings/images/plugins/java.gif</pluginIcon>
+				<pluginName>java</pluginName>
+			</row>
+		</pluginsIcons>
+		<visitLocalTime>12:34:06</visitLocalTime>
+		<visitLocalHour>12</visitLocalHour>
+		<daysSinceLastVisit>0</daysSinceLastVisit>
+		
+		
+		
+		
+		
+	</row>
+	<row>
+		<idSite>1</idSite>
+		<idVisit>2</idVisit>
+		<visitIp>111.1.1.1</visitIp>
+		
+		<actionDetails>
+			<row>
+				<type>action</type>
+				<url>http://www.example.org/page</url>
+				<pageTitle>Ads</pageTitle>
+				<pageIdAction>2</pageIdAction>
+				
+				<pageId>13</pageId>
+				<generationTime>0.33s</generationTime>
+				<timeSpent>0</timeSpent>
+				<timeSpentPretty>0s</timeSpentPretty>
+				<icon />
+			</row>
+		</actionDetails>
+		<goalConversions>0</goalConversions>
+		<siteCurrency>USD</siteCurrency>
+		<siteCurrencySymbol>$</siteCurrencySymbol>
+		
+		
+		
+		
+		<searches>0</searches>
+		<actions>1</actions>
+		<userId />
+		<visitorType>new</visitorType>
+		<visitorTypeIcon />
+		<visitConverted>0</visitConverted>
+		<visitConvertedIcon />
+		<visitCount>1</visitCount>
+		
+		<visitEcommerceStatus>none</visitEcommerceStatus>
+		<visitEcommerceStatusIcon />
+		<daysSinceFirstVisit>0</daysSinceFirstVisit>
+		<daysSinceLastEcommerceOrder>0</daysSinceLastEcommerceOrder>
+		<visitDuration>271</visitDuration>
+		<visitDurationPretty>4 min 31s</visitDurationPretty>
+		<customVariables>
+		</customVariables>
+		<deviceType>Desktop</deviceType>
+		<events>0</events>
+		<provider>Unknown</provider>
+		<providerName>Unknown</providerName>
+		<providerUrl>http://piwik.org/faq/general/#faq_52</providerUrl>
+		<referrerType>direct</referrerType>
+		<referrerTypeName>Direct Entry</referrerTypeName>
+		<referrerName />
+		<referrerKeyword />
+		<referrerKeywordPosition />
+		<referrerUrl />
+		<referrerSearchEngineUrl />
+		<referrerSearchEngineIcon />
+		<continent>Europe</continent>
+		<continentCode>eur</continentCode>
+		<country>France</country>
+		<countryCode>fr</countryCode>
+		<countryFlag>plugins/UserCountry/images/flags/fr.png</countryFlag>
+		<region />
+		<regionCode />
+		<city />
+		<location>France</location>
+		<latitude />
+		<longitude />
+		<operatingSystem>Windows XP</operatingSystem>
+		<operatingSystemCode>WXP</operatingSystemCode>
+		<operatingSystemShortName>Win XP</operatingSystemShortName>
+		<operatingSystemIcon>plugins/UserSettings/images/os/WXP.gif</operatingSystemIcon>
+		<browserFamily>gecko</browserFamily>
+		<browserFamilyDescription>Gecko (Firefox)</browserFamilyDescription>
+		<browserName>Firefox 3.6</browserName>
+		<browserIcon>plugins/UserSettings/images/browsers/FF.gif</browserIcon>
+		<browserCode>FF</browserCode>
+		<browserVersion>3.6</browserVersion>
+		<screenType>normal</screenType>
+		<resolution>1024x768</resolution>
+		<screenTypeIcon>plugins/UserSettings/images/screens/normal.gif</screenTypeIcon>
+		<plugins>director</plugins>
+		<pluginsIcons>
+			<row>
+				<pluginIcon>plugins/UserSettings/images/plugins/director.gif</pluginIcon>
+				<pluginName>director</pluginName>
+			</row>
+		</pluginsIcons>
+		<visitLocalTime>12:34:06</visitLocalTime>
+		<visitLocalHour>12</visitLocalHour>
+		<daysSinceLastVisit>0</daysSinceLastVisit>
+		
+		
+		
+		
+		
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents_contentTargetMatch__Actions.getPageUrls_day.xml b/plugins/Contents/tests/System/processed/test_Contents_contentTargetMatch__Actions.getPageUrls_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..c234bed59e963e268d7a9bc05348d941758c4aa9
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents_contentTargetMatch__Actions.getPageUrls_day.xml
@@ -0,0 +1,2 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result />
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents_contentTargetMatch__Contents.getContentNames_day.xml b/plugins/Contents/tests/System/processed/test_Contents_contentTargetMatch__Contents.getContentNames_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..5212486a1c743990a3ea7fbfa8dcbf35ccd931e8
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents_contentTargetMatch__Contents.getContentNames_day.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<label>ImageAd</label>
+		<nb_uniq_visitors>4</nb_uniq_visitors>
+		<nb_visits>4</nb_visits>
+		<nb_impressions>4</nb_impressions>
+		<nb_interactions>2</nb_interactions>
+		<interaction_rate>50%</interaction_rate>
+		<contentTarget>http://www.example.com</contentTarget>
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents_contentTargetMatch__Contents.getContentPieces_day.xml b/plugins/Contents/tests/System/processed/test_Contents_contentTargetMatch__Contents.getContentPieces_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..ac1d39a57792ccf6b6e575066e9f9c7db99f4ac8
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents_contentTargetMatch__Contents.getContentPieces_day.xml
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<label>/path/ad.jpg</label>
+		<nb_uniq_visitors>2</nb_uniq_visitors>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>2</nb_interactions>
+		<interaction_rate>100%</interaction_rate>
+		<contentTarget>http://www.example.com</contentTarget>
+	</row>
+	<row>
+		<label>/path/ad2.jpg</label>
+		<nb_uniq_visitors>2</nb_uniq_visitors>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>0</nb_interactions>
+		<interaction_rate>0%</interaction_rate>
+		<contentTarget>http://www.example.com</contentTarget>
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_Contents_contentTargetMatch__Live.getLastVisitsDetails_day.xml b/plugins/Contents/tests/System/processed/test_Contents_contentTargetMatch__Live.getLastVisitsDetails_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..989f816722569544d52920872adc903958cc58b6
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_Contents_contentTargetMatch__Live.getLastVisitsDetails_day.xml
@@ -0,0 +1,199 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<idSite>1</idSite>
+		<idVisit>1</idVisit>
+		<visitIp>156.5.3.2</visitIp>
+		
+		<actionDetails>
+			<row>
+				<type>action</type>
+				<url>http://www.example.org/page</url>
+				<pageTitle>Ads</pageTitle>
+				<pageIdAction>2</pageIdAction>
+				
+				<pageId>1</pageId>
+				<generationTime>0.33s</generationTime>
+				<timeSpent>0</timeSpent>
+				<timeSpentPretty>0s</timeSpentPretty>
+				<icon />
+			</row>
+		</actionDetails>
+		<goalConversions>0</goalConversions>
+		<siteCurrency>USD</siteCurrency>
+		<siteCurrencySymbol>$</siteCurrencySymbol>
+		
+		
+		
+		
+		<searches>0</searches>
+		<actions>1</actions>
+		<userId />
+		<visitorType>new</visitorType>
+		<visitorTypeIcon />
+		<visitConverted>0</visitConverted>
+		<visitConvertedIcon />
+		<visitCount>1</visitCount>
+		
+		<visitEcommerceStatus>none</visitEcommerceStatus>
+		<visitEcommerceStatusIcon />
+		<daysSinceFirstVisit>0</daysSinceFirstVisit>
+		<daysSinceLastEcommerceOrder>0</daysSinceLastEcommerceOrder>
+		<visitDuration>271</visitDuration>
+		<visitDurationPretty>4 min 31s</visitDurationPretty>
+		<customVariables>
+		</customVariables>
+		<deviceType>Desktop</deviceType>
+		<events>0</events>
+		<provider>Unknown</provider>
+		<providerName>Unknown</providerName>
+		<providerUrl>http://piwik.org/faq/general/#faq_52</providerUrl>
+		<referrerType>direct</referrerType>
+		<referrerTypeName>Direct Entry</referrerTypeName>
+		<referrerName />
+		<referrerKeyword />
+		<referrerKeywordPosition />
+		<referrerUrl />
+		<referrerSearchEngineUrl />
+		<referrerSearchEngineIcon />
+		<continent>Europe</continent>
+		<continentCode>eur</continentCode>
+		<country>France</country>
+		<countryCode>fr</countryCode>
+		<countryFlag>plugins/UserCountry/images/flags/fr.png</countryFlag>
+		<region />
+		<regionCode />
+		<city />
+		<location>France</location>
+		<latitude />
+		<longitude />
+		<operatingSystem>Windows XP</operatingSystem>
+		<operatingSystemCode>WXP</operatingSystemCode>
+		<operatingSystemShortName>Win XP</operatingSystemShortName>
+		<operatingSystemIcon>plugins/UserSettings/images/os/WXP.gif</operatingSystemIcon>
+		<browserFamily>gecko</browserFamily>
+		<browserFamilyDescription>Gecko (Firefox)</browserFamilyDescription>
+		<browserName>Firefox 3.6</browserName>
+		<browserIcon>plugins/UserSettings/images/browsers/FF.gif</browserIcon>
+		<browserCode>FF</browserCode>
+		<browserVersion>3.6</browserVersion>
+		<screenType>normal</screenType>
+		<resolution>1024x768</resolution>
+		<screenTypeIcon>plugins/UserSettings/images/screens/normal.gif</screenTypeIcon>
+		<plugins>flash, java</plugins>
+		<pluginsIcons>
+			<row>
+				<pluginIcon>plugins/UserSettings/images/plugins/flash.gif</pluginIcon>
+				<pluginName>flash</pluginName>
+			</row>
+			<row>
+				<pluginIcon>plugins/UserSettings/images/plugins/java.gif</pluginIcon>
+				<pluginName>java</pluginName>
+			</row>
+		</pluginsIcons>
+		<visitLocalTime>12:34:06</visitLocalTime>
+		<visitLocalHour>12</visitLocalHour>
+		<daysSinceLastVisit>0</daysSinceLastVisit>
+		
+		
+		
+		
+		
+	</row>
+	<row>
+		<idSite>1</idSite>
+		<idVisit>2</idVisit>
+		<visitIp>111.1.1.1</visitIp>
+		
+		<actionDetails>
+			<row>
+				<type>action</type>
+				<url>http://www.example.org/page</url>
+				<pageTitle>Ads</pageTitle>
+				<pageIdAction>2</pageIdAction>
+				
+				<pageId>13</pageId>
+				<generationTime>0.33s</generationTime>
+				<timeSpent>0</timeSpent>
+				<timeSpentPretty>0s</timeSpentPretty>
+				<icon />
+			</row>
+		</actionDetails>
+		<goalConversions>0</goalConversions>
+		<siteCurrency>USD</siteCurrency>
+		<siteCurrencySymbol>$</siteCurrencySymbol>
+		
+		
+		
+		
+		<searches>0</searches>
+		<actions>1</actions>
+		<userId />
+		<visitorType>new</visitorType>
+		<visitorTypeIcon />
+		<visitConverted>0</visitConverted>
+		<visitConvertedIcon />
+		<visitCount>1</visitCount>
+		
+		<visitEcommerceStatus>none</visitEcommerceStatus>
+		<visitEcommerceStatusIcon />
+		<daysSinceFirstVisit>0</daysSinceFirstVisit>
+		<daysSinceLastEcommerceOrder>0</daysSinceLastEcommerceOrder>
+		<visitDuration>271</visitDuration>
+		<visitDurationPretty>4 min 31s</visitDurationPretty>
+		<customVariables>
+		</customVariables>
+		<deviceType>Desktop</deviceType>
+		<events>0</events>
+		<provider>Unknown</provider>
+		<providerName>Unknown</providerName>
+		<providerUrl>http://piwik.org/faq/general/#faq_52</providerUrl>
+		<referrerType>direct</referrerType>
+		<referrerTypeName>Direct Entry</referrerTypeName>
+		<referrerName />
+		<referrerKeyword />
+		<referrerKeywordPosition />
+		<referrerUrl />
+		<referrerSearchEngineUrl />
+		<referrerSearchEngineIcon />
+		<continent>Europe</continent>
+		<continentCode>eur</continentCode>
+		<country>France</country>
+		<countryCode>fr</countryCode>
+		<countryFlag>plugins/UserCountry/images/flags/fr.png</countryFlag>
+		<region />
+		<regionCode />
+		<city />
+		<location>France</location>
+		<latitude />
+		<longitude />
+		<operatingSystem>Windows XP</operatingSystem>
+		<operatingSystemCode>WXP</operatingSystemCode>
+		<operatingSystemShortName>Win XP</operatingSystemShortName>
+		<operatingSystemIcon>plugins/UserSettings/images/os/WXP.gif</operatingSystemIcon>
+		<browserFamily>gecko</browserFamily>
+		<browserFamilyDescription>Gecko (Firefox)</browserFamilyDescription>
+		<browserName>Firefox 3.6</browserName>
+		<browserIcon>plugins/UserSettings/images/browsers/FF.gif</browserIcon>
+		<browserCode>FF</browserCode>
+		<browserVersion>3.6</browserVersion>
+		<screenType>normal</screenType>
+		<resolution>1024x768</resolution>
+		<screenTypeIcon>plugins/UserSettings/images/screens/normal.gif</screenTypeIcon>
+		<plugins>director</plugins>
+		<pluginsIcons>
+			<row>
+				<pluginIcon>plugins/UserSettings/images/plugins/director.gif</pluginIcon>
+				<pluginName>director</pluginName>
+			</row>
+		</pluginsIcons>
+		<visitLocalTime>12:34:06</visitLocalTime>
+		<visitLocalHour>12</visitLocalHour>
+		<daysSinceLastVisit>0</daysSinceLastVisit>
+		
+		
+		
+		
+		
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_ContentscontentNameOrPieceMatch__Actions.getPageUrls_day.xml b/plugins/Contents/tests/System/processed/test_ContentscontentNameOrPieceMatch__Actions.getPageUrls_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..c234bed59e963e268d7a9bc05348d941758c4aa9
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_ContentscontentNameOrPieceMatch__Actions.getPageUrls_day.xml
@@ -0,0 +1,2 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result />
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_ContentscontentNameOrPieceMatch__Contents.getContentNames_day.xml b/plugins/Contents/tests/System/processed/test_ContentscontentNameOrPieceMatch__Contents.getContentNames_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..17b781db1cd340769a4f2712117938b9de27041a
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_ContentscontentNameOrPieceMatch__Contents.getContentNames_day.xml
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<label>ImageAd</label>
+		<nb_uniq_visitors>8</nb_uniq_visitors>
+		<nb_visits>8</nb_visits>
+		<nb_impressions>8</nb_impressions>
+		<nb_interactions>2</nb_interactions>
+		<interaction_rate>25%</interaction_rate>
+		<contentTarget>http://www.example.com</contentTarget>
+	</row>
+	<row>
+		<label>Text Ad</label>
+		<nb_uniq_visitors>4</nb_uniq_visitors>
+		<nb_visits>4</nb_visits>
+		<nb_impressions>4</nb_impressions>
+		<nb_interactions>2</nb_interactions>
+		<interaction_rate>50%</interaction_rate>
+		<contentTarget>http://piwik.org/download</contentTarget>
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_ContentscontentNameOrPieceMatch__Contents.getContentPieces_day.xml b/plugins/Contents/tests/System/processed/test_ContentscontentNameOrPieceMatch__Contents.getContentPieces_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..7df6e4f0e16ff5d7938975b4cb0248892244fb29
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_ContentscontentNameOrPieceMatch__Contents.getContentPieces_day.xml
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<label>Click to download Piwik now</label>
+		<nb_uniq_visitors>4</nb_uniq_visitors>
+		<nb_visits>4</nb_visits>
+		<nb_impressions>4</nb_impressions>
+		<nb_interactions>2</nb_interactions>
+		<interaction_rate>50%</interaction_rate>
+		<contentTarget>http://piwik.org/download</contentTarget>
+	</row>
+	<row>
+		<label>/path/ad.jpg</label>
+		<nb_uniq_visitors>2</nb_uniq_visitors>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>2</nb_interactions>
+		<interaction_rate>100%</interaction_rate>
+		<contentTarget>http://www.example.com</contentTarget>
+	</row>
+	<row>
+		<label>/path/ad2.jpg</label>
+		<nb_uniq_visitors>2</nb_uniq_visitors>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>0</nb_interactions>
+		<interaction_rate>0%</interaction_rate>
+		<contentTarget>http://www.example.com</contentTarget>
+	</row>
+	<row>
+		<label>Content Piece not defined</label>
+		<nb_uniq_visitors>2</nb_uniq_visitors>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>0</nb_interactions>
+		<interaction_rate>0%</interaction_rate>
+		<contentTarget />
+	</row>
+	<row>
+		<label>Unknown</label>
+		<nb_uniq_visitors>2</nb_uniq_visitors>
+		<nb_visits>2</nb_visits>
+		<nb_impressions>2</nb_impressions>
+		<nb_interactions>0</nb_interactions>
+		<interaction_rate>0%</interaction_rate>
+		<contentTarget />
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/Contents/tests/System/processed/test_ContentscontentNameOrPieceMatch__Live.getLastVisitsDetails_day.xml b/plugins/Contents/tests/System/processed/test_ContentscontentNameOrPieceMatch__Live.getLastVisitsDetails_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..989f816722569544d52920872adc903958cc58b6
--- /dev/null
+++ b/plugins/Contents/tests/System/processed/test_ContentscontentNameOrPieceMatch__Live.getLastVisitsDetails_day.xml
@@ -0,0 +1,199 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<idSite>1</idSite>
+		<idVisit>1</idVisit>
+		<visitIp>156.5.3.2</visitIp>
+		
+		<actionDetails>
+			<row>
+				<type>action</type>
+				<url>http://www.example.org/page</url>
+				<pageTitle>Ads</pageTitle>
+				<pageIdAction>2</pageIdAction>
+				
+				<pageId>1</pageId>
+				<generationTime>0.33s</generationTime>
+				<timeSpent>0</timeSpent>
+				<timeSpentPretty>0s</timeSpentPretty>
+				<icon />
+			</row>
+		</actionDetails>
+		<goalConversions>0</goalConversions>
+		<siteCurrency>USD</siteCurrency>
+		<siteCurrencySymbol>$</siteCurrencySymbol>
+		
+		
+		
+		
+		<searches>0</searches>
+		<actions>1</actions>
+		<userId />
+		<visitorType>new</visitorType>
+		<visitorTypeIcon />
+		<visitConverted>0</visitConverted>
+		<visitConvertedIcon />
+		<visitCount>1</visitCount>
+		
+		<visitEcommerceStatus>none</visitEcommerceStatus>
+		<visitEcommerceStatusIcon />
+		<daysSinceFirstVisit>0</daysSinceFirstVisit>
+		<daysSinceLastEcommerceOrder>0</daysSinceLastEcommerceOrder>
+		<visitDuration>271</visitDuration>
+		<visitDurationPretty>4 min 31s</visitDurationPretty>
+		<customVariables>
+		</customVariables>
+		<deviceType>Desktop</deviceType>
+		<events>0</events>
+		<provider>Unknown</provider>
+		<providerName>Unknown</providerName>
+		<providerUrl>http://piwik.org/faq/general/#faq_52</providerUrl>
+		<referrerType>direct</referrerType>
+		<referrerTypeName>Direct Entry</referrerTypeName>
+		<referrerName />
+		<referrerKeyword />
+		<referrerKeywordPosition />
+		<referrerUrl />
+		<referrerSearchEngineUrl />
+		<referrerSearchEngineIcon />
+		<continent>Europe</continent>
+		<continentCode>eur</continentCode>
+		<country>France</country>
+		<countryCode>fr</countryCode>
+		<countryFlag>plugins/UserCountry/images/flags/fr.png</countryFlag>
+		<region />
+		<regionCode />
+		<city />
+		<location>France</location>
+		<latitude />
+		<longitude />
+		<operatingSystem>Windows XP</operatingSystem>
+		<operatingSystemCode>WXP</operatingSystemCode>
+		<operatingSystemShortName>Win XP</operatingSystemShortName>
+		<operatingSystemIcon>plugins/UserSettings/images/os/WXP.gif</operatingSystemIcon>
+		<browserFamily>gecko</browserFamily>
+		<browserFamilyDescription>Gecko (Firefox)</browserFamilyDescription>
+		<browserName>Firefox 3.6</browserName>
+		<browserIcon>plugins/UserSettings/images/browsers/FF.gif</browserIcon>
+		<browserCode>FF</browserCode>
+		<browserVersion>3.6</browserVersion>
+		<screenType>normal</screenType>
+		<resolution>1024x768</resolution>
+		<screenTypeIcon>plugins/UserSettings/images/screens/normal.gif</screenTypeIcon>
+		<plugins>flash, java</plugins>
+		<pluginsIcons>
+			<row>
+				<pluginIcon>plugins/UserSettings/images/plugins/flash.gif</pluginIcon>
+				<pluginName>flash</pluginName>
+			</row>
+			<row>
+				<pluginIcon>plugins/UserSettings/images/plugins/java.gif</pluginIcon>
+				<pluginName>java</pluginName>
+			</row>
+		</pluginsIcons>
+		<visitLocalTime>12:34:06</visitLocalTime>
+		<visitLocalHour>12</visitLocalHour>
+		<daysSinceLastVisit>0</daysSinceLastVisit>
+		
+		
+		
+		
+		
+	</row>
+	<row>
+		<idSite>1</idSite>
+		<idVisit>2</idVisit>
+		<visitIp>111.1.1.1</visitIp>
+		
+		<actionDetails>
+			<row>
+				<type>action</type>
+				<url>http://www.example.org/page</url>
+				<pageTitle>Ads</pageTitle>
+				<pageIdAction>2</pageIdAction>
+				
+				<pageId>13</pageId>
+				<generationTime>0.33s</generationTime>
+				<timeSpent>0</timeSpent>
+				<timeSpentPretty>0s</timeSpentPretty>
+				<icon />
+			</row>
+		</actionDetails>
+		<goalConversions>0</goalConversions>
+		<siteCurrency>USD</siteCurrency>
+		<siteCurrencySymbol>$</siteCurrencySymbol>
+		
+		
+		
+		
+		<searches>0</searches>
+		<actions>1</actions>
+		<userId />
+		<visitorType>new</visitorType>
+		<visitorTypeIcon />
+		<visitConverted>0</visitConverted>
+		<visitConvertedIcon />
+		<visitCount>1</visitCount>
+		
+		<visitEcommerceStatus>none</visitEcommerceStatus>
+		<visitEcommerceStatusIcon />
+		<daysSinceFirstVisit>0</daysSinceFirstVisit>
+		<daysSinceLastEcommerceOrder>0</daysSinceLastEcommerceOrder>
+		<visitDuration>271</visitDuration>
+		<visitDurationPretty>4 min 31s</visitDurationPretty>
+		<customVariables>
+		</customVariables>
+		<deviceType>Desktop</deviceType>
+		<events>0</events>
+		<provider>Unknown</provider>
+		<providerName>Unknown</providerName>
+		<providerUrl>http://piwik.org/faq/general/#faq_52</providerUrl>
+		<referrerType>direct</referrerType>
+		<referrerTypeName>Direct Entry</referrerTypeName>
+		<referrerName />
+		<referrerKeyword />
+		<referrerKeywordPosition />
+		<referrerUrl />
+		<referrerSearchEngineUrl />
+		<referrerSearchEngineIcon />
+		<continent>Europe</continent>
+		<continentCode>eur</continentCode>
+		<country>France</country>
+		<countryCode>fr</countryCode>
+		<countryFlag>plugins/UserCountry/images/flags/fr.png</countryFlag>
+		<region />
+		<regionCode />
+		<city />
+		<location>France</location>
+		<latitude />
+		<longitude />
+		<operatingSystem>Windows XP</operatingSystem>
+		<operatingSystemCode>WXP</operatingSystemCode>
+		<operatingSystemShortName>Win XP</operatingSystemShortName>
+		<operatingSystemIcon>plugins/UserSettings/images/os/WXP.gif</operatingSystemIcon>
+		<browserFamily>gecko</browserFamily>
+		<browserFamilyDescription>Gecko (Firefox)</browserFamilyDescription>
+		<browserName>Firefox 3.6</browserName>
+		<browserIcon>plugins/UserSettings/images/browsers/FF.gif</browserIcon>
+		<browserCode>FF</browserCode>
+		<browserVersion>3.6</browserVersion>
+		<screenType>normal</screenType>
+		<resolution>1024x768</resolution>
+		<screenTypeIcon>plugins/UserSettings/images/screens/normal.gif</screenTypeIcon>
+		<plugins>director</plugins>
+		<pluginsIcons>
+			<row>
+				<pluginIcon>plugins/UserSettings/images/plugins/director.gif</pluginIcon>
+				<pluginName>director</pluginName>
+			</row>
+		</pluginsIcons>
+		<visitLocalTime>12:34:06</visitLocalTime>
+		<visitLocalHour>12</visitLocalHour>
+		<daysSinceLastVisit>0</daysSinceLastVisit>
+		
+		
+		
+		
+		
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/CoreConsole/Commands/GenerateTest.php b/plugins/CoreConsole/Commands/GenerateTest.php
index 5b80e389a639a0902b23b52c25f0028fe7e41f91..6047f2ddc714b12d431b8666d52278fea61ef954 100644
--- a/plugins/CoreConsole/Commands/GenerateTest.php
+++ b/plugins/CoreConsole/Commands/GenerateTest.php
@@ -37,15 +37,9 @@ class GenerateTest extends GeneratePluginBase
         $replace       = array(
             'ExamplePlugin'    => $pluginName,
             'SimpleTest'       => $testName,
-            'SimpleSystemTest' => $testName,
-            '@group Plugins'   => '@group ' . $testType
+            'SimpleSystemTest' => $testName
          );
 
-        $testClass  = $this->getTestClass($testType);
-        if (!empty($testClass)) {
-            $replace['\PHPUnit_Framework_TestCase'] = $testClass;
-        }
-
         $whitelistFiles = $this->getTestFilesWhitelist($testType);
         $this->copyTemplateToPlugin($exampleFolder, $pluginName, $replace, $whitelistFiles);
 
@@ -112,23 +106,6 @@ class GenerateTest extends GeneratePluginBase
         return $this->askPluginNameAndValidate($input, $output, $pluginNames, $invalidName);
     }
 
-    /**
-     * @param $testType
-     * @return string
-     */
-    private function getTestClass($testType)
-    {
-        if ('Integration' == $testType) {
-            return '\IntegrationTestCase';
-        }
-
-        if ('Unit' == $testType) {
-            return '\PHPUnit_Framework_TestCase';
-        }
-
-        return '';
-    }
-
     public function getValidTypes()
     {
         return array('unit', 'integration', 'system');
@@ -172,20 +149,31 @@ class GenerateTest extends GeneratePluginBase
             return array(
                 '/.gitignore',
                 '/tests',
-                '/tests/SimpleSystemTest.php',
-                '/tests/expected',
-                '/tests/expected/test___API.get_day.xml',
-                '/tests/expected/test___Goals.getItemsSku_day.xml',
-                '/tests/processed',
-                '/tests/processed/.gitignore',
-                '/tests/fixtures',
-                '/tests/fixtures/SimpleFixtureTrackFewVisits.php'
+                '/tests/System',
+                '/tests/System/SimpleSystemTest.php',
+                '/tests/System/expected',
+                '/tests/System/expected/test___API.get_day.xml',
+                '/tests/System/expected/test___Goals.getItemsSku_day.xml',
+                '/tests/System/processed',
+                '/tests/System/processed/.gitignore',
+                '/tests/Fixtures',
+                '/tests/Fixtures/SimpleFixtureTrackFewVisits.php'
+            );
+        }
+
+        if ('Integration' == $testType) {
+
+            return array(
+                '/tests',
+                '/tests/Integration',
+                '/tests/Integration/SimpleTest.php'
             );
         }
 
         return array(
             '/tests',
-            '/tests/SimpleTest.php'
+            '/tests/Unit',
+            '/tests/Unit/SimpleTest.php'
         );
     }
 }
diff --git a/plugins/CoreConsole/TravisYmlView.php b/plugins/CoreConsole/TravisYmlView.php
index 9190f220ad863943179cfa5afa5fafca577a1ac1..a89b5f1df52f7c03301c10ae01dccec97e0f5b63 100644
--- a/plugins/CoreConsole/TravisYmlView.php
+++ b/plugins/CoreConsole/TravisYmlView.php
@@ -199,16 +199,16 @@ class TravisYmlView extends View
         $testsToExclude = array();
 
         if ($this->isTargetPluginContainsPluginTests()) {
-            $testsToRun[] = array('name' => 'IntegrationTests',
+            $testsToRun[] = array('name' => 'PluginTests',
                                   'vars' => "MYSQL_ADAPTER=PDO_MYSQL");
-            $testsToRun[] = array('name' => 'IntegrationTests',
+            $testsToRun[] = array('name' => 'PluginTests',
                                   'vars' => "MYSQL_ADAPTER=PDO_MYSQL TEST_AGAINST_CORE=latest_stable");
 
             $testsToExclude[] = array('description' => 'execute latest stable tests only w/ PHP 5.5',
                                       'php' => '5.3.3',
-                                      'env' => 'TEST_SUITE=IntegrationTests MYSQL_ADAPTER=PDO_MYSQL TEST_AGAINST_CORE=latest_stable');
+                                      'env' => 'TEST_SUITE=PluginTests MYSQL_ADAPTER=PDO_MYSQL TEST_AGAINST_CORE=latest_stable');
             $testsToExclude[] = array('php' => '5.4',
-                                      'env' => 'TEST_SUITE=IntegrationTests MYSQL_ADAPTER=PDO_MYSQL TEST_AGAINST_CORE=latest_stable');
+                                      'env' => 'TEST_SUITE=PluginTests MYSQL_ADAPTER=PDO_MYSQL TEST_AGAINST_CORE=latest_stable');
         }
 
         if ($this->isTargetPluginContainsUITests()) {
diff --git a/plugins/CoreConsole/tests/Unit/TravisYmlViewTest.php b/plugins/CoreConsole/tests/Integration/TravisYmlViewTest.php
similarity index 98%
rename from plugins/CoreConsole/tests/Unit/TravisYmlViewTest.php
rename to plugins/CoreConsole/tests/Integration/TravisYmlViewTest.php
index b35819c7f0ffdf8c1dc1359b6a77133fbf0a6439..f20e1c6d0f59cec844d5f20a84a2a7479a53a5a7 100644
--- a/plugins/CoreConsole/tests/Unit/TravisYmlViewTest.php
+++ b/plugins/CoreConsole/tests/Integration/TravisYmlViewTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  *
  */
-namespace Piwik\Plugins\CoreConsole\tests\Unit;
+namespace Piwik\Plugins\CoreConsole\tests\Integration;
 
 use Symfony\Component\Console\Output\ConsoleOutput;
 use Piwik\Plugins\CoreConsole\TravisYmlView;
@@ -61,7 +61,7 @@ class TravisYmlViewTest extends PHPUnit_Framework_TestCase
         $view->setPlugin('ExamplePlugin');
         $view->setExtraGlobalEnvVars(array('secure: artifactspass', 'secure: githubtoken'));
         $view->setGenerateYmlCommand('./console generate:travis-yml arg1 arg2');
-        $view->processExistingTravisYml(PIWIK_INCLUDE_PATH . '/plugins/CoreConsole/tests/resources/test.travis.yml');
+        $view->processExistingTravisYml(PIWIK_INCLUDE_PATH . '/plugins/CoreConsole/tests/Integration/resources/test.travis.yml');
         $output = $view->render();
 
         $yaml = Spyc::YAMLLoadString($output);
diff --git a/plugins/CoreConsole/tests/resources/test.travis.yml b/plugins/CoreConsole/tests/Integration/resources/test.travis.yml
similarity index 100%
rename from plugins/CoreConsole/tests/resources/test.travis.yml
rename to plugins/CoreConsole/tests/Integration/resources/test.travis.yml
diff --git a/plugins/CorePluginsAdmin/tests/UpdateCommunicationTest.php b/plugins/CorePluginsAdmin/tests/Integration/UpdateCommunicationTest.php
similarity index 99%
rename from plugins/CorePluginsAdmin/tests/UpdateCommunicationTest.php
rename to plugins/CorePluginsAdmin/tests/Integration/UpdateCommunicationTest.php
index 8da5e009281cf5eb580eca9e5a3b468b47521228..c57a3e0058cab95e4a79af9567cb75e265fd81c8 100644
--- a/plugins/CorePluginsAdmin/tests/UpdateCommunicationTest.php
+++ b/plugins/CorePluginsAdmin/tests/Integration/UpdateCommunicationTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\CorePluginsAdmin\tests;
+namespace Piwik\Plugins\CorePluginsAdmin\tests\Integration;
 
 use Piwik\Config;
 use Piwik\Option;
diff --git a/plugins/CoreUpdater/tests/UpdateCommunicationTest.php b/plugins/CoreUpdater/tests/Integration/UpdateCommunicationTest.php
similarity index 100%
rename from plugins/CoreUpdater/tests/UpdateCommunicationTest.php
rename to plugins/CoreUpdater/tests/Integration/UpdateCommunicationTest.php
diff --git a/plugins/CoreUpdater/tests/ModelTest.php b/plugins/CoreUpdater/tests/Unit/ModelTest.php
similarity index 100%
rename from plugins/CoreUpdater/tests/ModelTest.php
rename to plugins/CoreUpdater/tests/Unit/ModelTest.php
diff --git a/plugins/CustomVariables/.gitignore b/plugins/CustomVariables/.gitignore
new file mode 100644
index 0000000000000000000000000000000000000000..c8c9480010db494b8cf54ca8f9561e7a14ff51ea
--- /dev/null
+++ b/plugins/CustomVariables/.gitignore
@@ -0,0 +1 @@
+tests/System/processed/*xml
\ No newline at end of file
diff --git a/plugins/CustomVariables/tests/CustomVariablesTest.php b/plugins/CustomVariables/tests/Integration/CustomVariablesTest.php
similarity index 100%
rename from plugins/CustomVariables/tests/CustomVariablesTest.php
rename to plugins/CustomVariables/tests/Integration/CustomVariablesTest.php
diff --git a/plugins/CustomVariables/tests/ModelTest.php b/plugins/CustomVariables/tests/Integration/ModelTest.php
similarity index 99%
rename from plugins/CustomVariables/tests/ModelTest.php
rename to plugins/CustomVariables/tests/Integration/ModelTest.php
index db0afbbba994921e11ccec76116a6545566709ad..11d444b7487737dabe0be63a445fe3b5feb9a979 100644
--- a/plugins/CustomVariables/tests/ModelTest.php
+++ b/plugins/CustomVariables/tests/Integration/ModelTest.php
@@ -7,9 +7,7 @@
  */
 
 namespace Piwik\Plugins\CustomVariables\tests;
-use Piwik\Common;
 use Piwik\Db;
-use Piwik\DbHelper;
 use Piwik\Plugins\CustomVariables\Model;
 
 /**
diff --git a/plugins/CustomVariables/tests/CustomVariablesSystemTest.php b/plugins/CustomVariables/tests/System/CustomVariablesSystemTest.php
similarity index 100%
rename from plugins/CustomVariables/tests/CustomVariablesSystemTest.php
rename to plugins/CustomVariables/tests/System/CustomVariablesSystemTest.php
diff --git a/plugins/CustomVariables/tests/expected/test_CustomVariablesSystemTest__CustomVariables.getCustomVariables_day.xml b/plugins/CustomVariables/tests/System/expected/test_CustomVariablesSystemTest__CustomVariables.getCustomVariables_day.xml
similarity index 100%
rename from plugins/CustomVariables/tests/expected/test_CustomVariablesSystemTest__CustomVariables.getCustomVariables_day.xml
rename to plugins/CustomVariables/tests/System/expected/test_CustomVariablesSystemTest__CustomVariables.getCustomVariables_day.xml
diff --git a/plugins/CustomVariables/tests/expected/test_CustomVariablesSystemTest__Live.getLastVisitsDetails_day.xml b/plugins/CustomVariables/tests/System/expected/test_CustomVariablesSystemTest__Live.getLastVisitsDetails_day.xml
similarity index 100%
rename from plugins/CustomVariables/tests/expected/test_CustomVariablesSystemTest__Live.getLastVisitsDetails_day.xml
rename to plugins/CustomVariables/tests/System/expected/test_CustomVariablesSystemTest__Live.getLastVisitsDetails_day.xml
diff --git a/plugins/CustomVariables/tests/processed/test_CustomVariablesIntegrationTest__CustomVariables.getCustomVariables_day.xml b/plugins/CustomVariables/tests/System/processed/test_CustomVariablesIntegrationTest__CustomVariables.getCustomVariables_day.xml
similarity index 100%
rename from plugins/CustomVariables/tests/processed/test_CustomVariablesIntegrationTest__CustomVariables.getCustomVariables_day.xml
rename to plugins/CustomVariables/tests/System/processed/test_CustomVariablesIntegrationTest__CustomVariables.getCustomVariables_day.xml
diff --git a/plugins/CustomVariables/tests/processed/test_CustomVariablesIntegrationTest__Live.getLastVisitsDetails_day.xml b/plugins/CustomVariables/tests/System/processed/test_CustomVariablesIntegrationTest__Live.getLastVisitsDetails_day.xml
similarity index 100%
rename from plugins/CustomVariables/tests/processed/test_CustomVariablesIntegrationTest__Live.getLastVisitsDetails_day.xml
rename to plugins/CustomVariables/tests/System/processed/test_CustomVariablesIntegrationTest__Live.getLastVisitsDetails_day.xml
diff --git a/plugins/CustomVariables/tests/processed/test_CustomVariablesSystemTest__CustomVariables.getCustomVariables_day.xml b/plugins/CustomVariables/tests/System/processed/test_CustomVariablesSystemTest__CustomVariables.getCustomVariables_day.xml
similarity index 100%
rename from plugins/CustomVariables/tests/processed/test_CustomVariablesSystemTest__CustomVariables.getCustomVariables_day.xml
rename to plugins/CustomVariables/tests/System/processed/test_CustomVariablesSystemTest__CustomVariables.getCustomVariables_day.xml
diff --git a/plugins/CustomVariables/tests/processed/test_CustomVariablesSystemTest__Live.getLastVisitsDetails_day.xml b/plugins/CustomVariables/tests/System/processed/test_CustomVariablesSystemTest__Live.getLastVisitsDetails_day.xml
similarity index 100%
rename from plugins/CustomVariables/tests/processed/test_CustomVariablesSystemTest__Live.getLastVisitsDetails_day.xml
rename to plugins/CustomVariables/tests/System/processed/test_CustomVariablesSystemTest__Live.getLastVisitsDetails_day.xml
diff --git a/plugins/ExamplePlugin/.gitignore b/plugins/ExamplePlugin/.gitignore
index b141f4501fd9f6d83093f837bc8c9f347b8edf31..c8c9480010db494b8cf54ca8f9561e7a14ff51ea 100644
--- a/plugins/ExamplePlugin/.gitignore
+++ b/plugins/ExamplePlugin/.gitignore
@@ -1 +1 @@
-tests/processed/*xml
\ No newline at end of file
+tests/System/processed/*xml
\ No newline at end of file
diff --git a/plugins/ExamplePlugin/tests/fixtures/SimpleFixtureTrackFewVisits.php b/plugins/ExamplePlugin/tests/Fixtures/SimpleFixtureTrackFewVisits.php
similarity index 98%
rename from plugins/ExamplePlugin/tests/fixtures/SimpleFixtureTrackFewVisits.php
rename to plugins/ExamplePlugin/tests/Fixtures/SimpleFixtureTrackFewVisits.php
index ea9755f6a1b86f26b5ac0c42e3c687dc68cf96fc..2d455ce70ac3eb183fba532db73d29104e2b5726 100644
--- a/plugins/ExamplePlugin/tests/fixtures/SimpleFixtureTrackFewVisits.php
+++ b/plugins/ExamplePlugin/tests/Fixtures/SimpleFixtureTrackFewVisits.php
@@ -5,7 +5,7 @@
  * @link    http://piwik.org
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
-namespace Piwik\Plugins\ExamplePlugin\tests\fixtures;
+namespace Piwik\Plugins\ExamplePlugin\tests\Fixtures;
 
 use Piwik\Date;
 use Piwik\Tests\Fixture;
diff --git a/plugins/ExamplePlugin/tests/Integration/SimpleTest.php b/plugins/ExamplePlugin/tests/Integration/SimpleTest.php
new file mode 100644
index 0000000000000000000000000000000000000000..c096b2946b5eb4390a71ba8dcf210bb3c8cd83a3
--- /dev/null
+++ b/plugins/ExamplePlugin/tests/Integration/SimpleTest.php
@@ -0,0 +1,24 @@
+<?php
+/**
+ * Piwik - free/libre analytics platform
+ *
+ * @link http://piwik.org
+ * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
+ */
+
+namespace Piwik\Plugins\ExamplePlugin\tests\Integration;
+
+/**
+ * @group ExamplePlugin
+ * @group SimpleTest
+ * @group Plugins
+ */
+class SimpleTest extends \IntegrationTestCase
+{
+
+    public function testSimpleAddition()
+    {
+        $this->assertEquals(2, 1+1);
+    }
+
+}
diff --git a/plugins/ExamplePlugin/tests/SimpleSystemTest.php b/plugins/ExamplePlugin/tests/System/SimpleSystemTest.php
similarity index 96%
rename from plugins/ExamplePlugin/tests/SimpleSystemTest.php
rename to plugins/ExamplePlugin/tests/System/SimpleSystemTest.php
index ec36ab8e31ae7b82fd38c97f76762e661b92652b..574e6b5a79cb743f3b07cd0635a200ecfeec03f2 100644
--- a/plugins/ExamplePlugin/tests/SimpleSystemTest.php
+++ b/plugins/ExamplePlugin/tests/System/SimpleSystemTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\ExamplePlugin\tests;
+namespace Piwik\Plugins\ExamplePlugin\tests\System;
 
 use Piwik\Plugins\ExamplePlugin\tests\fixtures\SimpleFixtureTrackFewVisits;
 use Piwik\Tests\SystemTestCase;
diff --git a/plugins/ExamplePlugin/tests/expected/test___API.get_day.xml b/plugins/ExamplePlugin/tests/System/expected/test___API.get_day.xml
similarity index 100%
rename from plugins/ExamplePlugin/tests/expected/test___API.get_day.xml
rename to plugins/ExamplePlugin/tests/System/expected/test___API.get_day.xml
diff --git a/plugins/ExamplePlugin/tests/expected/test___Goals.getItemsSku_day.xml b/plugins/ExamplePlugin/tests/System/expected/test___Goals.getItemsSku_day.xml
similarity index 100%
rename from plugins/ExamplePlugin/tests/expected/test___Goals.getItemsSku_day.xml
rename to plugins/ExamplePlugin/tests/System/expected/test___Goals.getItemsSku_day.xml
diff --git a/plugins/ExamplePlugin/tests/processed/.gitkeep b/plugins/ExamplePlugin/tests/System/processed/.gitkeep
similarity index 100%
rename from plugins/ExamplePlugin/tests/processed/.gitkeep
rename to plugins/ExamplePlugin/tests/System/processed/.gitkeep
diff --git a/plugins/ExamplePlugin/tests/System/processed/test___API.get_day.xml b/plugins/ExamplePlugin/tests/System/processed/test___API.get_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..1cfef75f4b8f4578254f4c76a0832926c7ca9cd5
--- /dev/null
+++ b/plugins/ExamplePlugin/tests/System/processed/test___API.get_day.xml
@@ -0,0 +1,30 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<nb_uniq_visitors>2</nb_uniq_visitors>
+	<nb_visits>2</nb_visits>
+	<nb_users>0</nb_users>
+	<nb_actions>4</nb_actions>
+	<max_actions>2</max_actions>
+	<bounce_rate>0%</bounce_rate>
+	<nb_actions_per_visit>2</nb_actions_per_visit>
+	<avg_time_on_site>632</avg_time_on_site>
+	<nb_visits_returning>0</nb_visits_returning>
+	<nb_actions_returning>0</nb_actions_returning>
+	<nb_uniq_visitors_returning>0</nb_uniq_visitors_returning>
+	<bounce_rate_returning>0%</bounce_rate_returning>
+	<nb_actions_per_visit_returning>0</nb_actions_per_visit_returning>
+	<avg_time_on_site_returning>0</avg_time_on_site_returning>
+	<nb_conversions>1</nb_conversions>
+	<nb_visits_converted>1</nb_visits_converted>
+	<conversion_rate>50</conversion_rate>
+	<revenue>2541</revenue>
+	<nb_pageviews>3</nb_pageviews>
+	<nb_uniq_pageviews>3</nb_uniq_pageviews>
+	<nb_downloads>0</nb_downloads>
+	<nb_uniq_downloads>0</nb_uniq_downloads>
+	<nb_outlinks>0</nb_outlinks>
+	<nb_uniq_outlinks>0</nb_uniq_outlinks>
+	<nb_searches>1</nb_searches>
+	<nb_keywords>1</nb_keywords>
+	<avg_time_generation>0</avg_time_generation>
+</result>
\ No newline at end of file
diff --git a/plugins/ExamplePlugin/tests/System/processed/test___Goals.getItemsSku_day.xml b/plugins/ExamplePlugin/tests/System/processed/test___Goals.getItemsSku_day.xml
new file mode 100644
index 0000000000000000000000000000000000000000..ba820ed649851a5bebc328dad473c8198433d565
--- /dev/null
+++ b/plugins/ExamplePlugin/tests/System/processed/test___Goals.getItemsSku_day.xml
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<result>
+	<row>
+		<label>SKU_ID</label>
+		<revenue>25641</revenue>
+		<quantity>33</quantity>
+		<orders>1</orders>
+		<avg_price>777</avg_price>
+		<avg_quantity>33</avg_quantity>
+		<conversion_rate>0%</conversion_rate>
+	</row>
+</result>
\ No newline at end of file
diff --git a/plugins/ExamplePlugin/tests/SimpleTest.php b/plugins/ExamplePlugin/tests/Unit/SimpleTest.php
similarity index 88%
rename from plugins/ExamplePlugin/tests/SimpleTest.php
rename to plugins/ExamplePlugin/tests/Unit/SimpleTest.php
index 0fdc86062c60205e38d726277888589978f80757..396ee2078536206c8b6167febd420c65f7e661c5 100644
--- a/plugins/ExamplePlugin/tests/SimpleTest.php
+++ b/plugins/ExamplePlugin/tests/Unit/SimpleTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\ExamplePlugin\tests;
+namespace Piwik\Plugins\ExamplePlugin\tests\Unit;
 
 /**
  * @group ExamplePlugin
diff --git a/plugins/Goals/tests/APITest.php b/plugins/Goals/tests/Integration/APITest.php
similarity index 99%
rename from plugins/Goals/tests/APITest.php
rename to plugins/Goals/tests/Integration/APITest.php
index 39672b722de80d9c6031ac1fd9e854a8fd4ca859..6251628430c0921bcc69fa111040cde56cb88f16 100644
--- a/plugins/Goals/tests/APITest.php
+++ b/plugins/Goals/tests/Integration/APITest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\Goals\tests;
+namespace Piwik\Plugins\Goals\tests\Integration;
 use Piwik\Access;
 use Piwik\Piwik;
 use Piwik\Plugins\Goals\API;
diff --git a/plugins/Insights/tests/ApiTest.php b/plugins/Insights/tests/Integration/ApiTest.php
similarity index 100%
rename from plugins/Insights/tests/ApiTest.php
rename to plugins/Insights/tests/Integration/ApiTest.php
diff --git a/plugins/Insights/tests/ModelTest.php b/plugins/Insights/tests/Integration/ModelTest.php
similarity index 100%
rename from plugins/Insights/tests/ModelTest.php
rename to plugins/Insights/tests/Integration/ModelTest.php
diff --git a/plugins/Insights/tests/BaseUnitTest.php b/plugins/Insights/tests/Unit/BaseUnitTest.php
similarity index 100%
rename from plugins/Insights/tests/BaseUnitTest.php
rename to plugins/Insights/tests/Unit/BaseUnitTest.php
diff --git a/plugins/Insights/tests/FilterExcludeLowValueTest.php b/plugins/Insights/tests/Unit/FilterExcludeLowValueTest.php
similarity index 100%
rename from plugins/Insights/tests/FilterExcludeLowValueTest.php
rename to plugins/Insights/tests/Unit/FilterExcludeLowValueTest.php
diff --git a/plugins/Insights/tests/FilterInsightTest.php b/plugins/Insights/tests/Unit/FilterInsightTest.php
similarity index 100%
rename from plugins/Insights/tests/FilterInsightTest.php
rename to plugins/Insights/tests/Unit/FilterInsightTest.php
diff --git a/plugins/Insights/tests/FilterLimitTest.php b/plugins/Insights/tests/Unit/FilterLimitTest.php
similarity index 100%
rename from plugins/Insights/tests/FilterLimitTest.php
rename to plugins/Insights/tests/Unit/FilterLimitTest.php
diff --git a/plugins/Insights/tests/FilterMinGrowthTest.php b/plugins/Insights/tests/Unit/FilterMinGrowthTest.php
similarity index 100%
rename from plugins/Insights/tests/FilterMinGrowthTest.php
rename to plugins/Insights/tests/Unit/FilterMinGrowthTest.php
diff --git a/plugins/Insights/tests/FilterOrderByTest.php b/plugins/Insights/tests/Unit/FilterOrderByTest.php
similarity index 100%
rename from plugins/Insights/tests/FilterOrderByTest.php
rename to plugins/Insights/tests/Unit/FilterOrderByTest.php
diff --git a/plugins/Insights/tests/InsightReportTest.php b/plugins/Insights/tests/Unit/InsightReportTest.php
similarity index 100%
rename from plugins/Insights/tests/InsightReportTest.php
rename to plugins/Insights/tests/Unit/InsightReportTest.php
diff --git a/plugins/LanguagesManager/tests/LanguagesManagerTest.php b/plugins/LanguagesManager/tests/Integration/LanguagesManagerTest.php
similarity index 100%
rename from plugins/LanguagesManager/tests/LanguagesManagerTest.php
rename to plugins/LanguagesManager/tests/Integration/LanguagesManagerTest.php
diff --git a/plugins/LeftMenu/tests/APITest.php b/plugins/LeftMenu/tests/Integration/APITest.php
similarity index 98%
rename from plugins/LeftMenu/tests/APITest.php
rename to plugins/LeftMenu/tests/Integration/APITest.php
index 1b80cdc0d85915300ea4eaa560a633026b9b970a..0677f57c734c5a006140e447647f3152469f92ba 100644
--- a/plugins/LeftMenu/tests/APITest.php
+++ b/plugins/LeftMenu/tests/Integration/APITest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\LeftMenu\tests;
+namespace Piwik\Plugins\LeftMenu\tests\Integration;
 
 use Piwik\Access;
 use Piwik\Plugins\LeftMenu\API;
diff --git a/plugins/Live/tests/APITest.php b/plugins/Live/tests/Integration/APITest.php
similarity index 98%
rename from plugins/Live/tests/APITest.php
rename to plugins/Live/tests/Integration/APITest.php
index 5bdf6f2f228ae00a39daf437623c8973610f007b..7c49eb2eae00131523647f4d4248792e2761ebcc 100644
--- a/plugins/Live/tests/APITest.php
+++ b/plugins/Live/tests/Integration/APITest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\Live\tests;
+namespace Piwik\Plugins\Live\tests\Integration;
 
 use Piwik\Date;
 use Piwik\Db;
diff --git a/plugins/Login/tests/LoginTest.php b/plugins/Login/tests/Integration/LoginTest.php
similarity index 99%
rename from plugins/Login/tests/LoginTest.php
rename to plugins/Login/tests/Integration/LoginTest.php
index 8e431c93726cb2438c1bd505a7f3f1be2c567585..4af87cc11533d20aff7885ad2f256c2a5d280cb5 100644
--- a/plugins/Login/tests/LoginTest.php
+++ b/plugins/Login/tests/Integration/LoginTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\Login\tests;
+namespace Piwik\Plugins\Login\tests\Integration;
 
 use Piwik\Access;
 use Piwik\AuthResult;
diff --git a/plugins/MobileMessaging/tests/MobileMessagingTest.php b/plugins/MobileMessaging/tests/Integration/MobileMessagingTest.php
similarity index 99%
rename from plugins/MobileMessaging/tests/MobileMessagingTest.php
rename to plugins/MobileMessaging/tests/Integration/MobileMessagingTest.php
index dab19beb8389bc637b9875a9b5701d12d514038b..35479dcea8a4bc23e6d3fb9a65da4e84f31d671a 100644
--- a/plugins/MobileMessaging/tests/MobileMessagingTest.php
+++ b/plugins/MobileMessaging/tests/Integration/MobileMessagingTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\MobileMessaging\tests;
+namespace Piwik\Plugins\MobileMessaging\tests\Integration;
 
 use Piwik\Access;
 use Piwik\Plugins\MobileMessaging\API as APIMobileMessaging;
diff --git a/plugins/MultiSites/tests/MultiSitesTest.php b/plugins/MultiSites/tests/Integration/MultiSitesTest.php
similarity index 96%
rename from plugins/MultiSites/tests/MultiSitesTest.php
rename to plugins/MultiSites/tests/Integration/MultiSitesTest.php
index 9f317d5ca758e9a46d2212de4059fdf893f88061..5f07c7131c194e061dbc8a35db406d6d053dc96f 100644
--- a/plugins/MultiSites/tests/MultiSitesTest.php
+++ b/plugins/MultiSites/tests/Integration/MultiSitesTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\MultiSites\tests;
+namespace Piwik\Plugins\MultiSites\tests\Integration;
 
 use Piwik\Access;
 use Piwik\Plugins\MultiSites\API as APIMultiSites;
diff --git a/plugins/PrivacyManager/tests/PrivacyManagerConfigTest.php b/plugins/PrivacyManager/tests/Integration/PrivacyManagerConfigTest.php
similarity index 100%
rename from plugins/PrivacyManager/tests/PrivacyManagerConfigTest.php
rename to plugins/PrivacyManager/tests/Integration/PrivacyManagerConfigTest.php
diff --git a/plugins/PrivacyManager/tests/PrivacyManagerTest.php b/plugins/PrivacyManager/tests/Integration/PrivacyManagerTest.php
similarity index 100%
rename from plugins/PrivacyManager/tests/PrivacyManagerTest.php
rename to plugins/PrivacyManager/tests/Integration/PrivacyManagerTest.php
diff --git a/plugins/PrivacyManager/tests/AnonymizeIPTest.php b/plugins/PrivacyManager/tests/Unit/AnonymizeIPTest.php
similarity index 100%
rename from plugins/PrivacyManager/tests/AnonymizeIPTest.php
rename to plugins/PrivacyManager/tests/Unit/AnonymizeIPTest.php
diff --git a/plugins/Proxy/tests/ProxyTest.php b/plugins/Proxy/tests/Unit/ProxyTest.php
similarity index 96%
rename from plugins/Proxy/tests/ProxyTest.php
rename to plugins/Proxy/tests/Unit/ProxyTest.php
index 8b460a35ccc16083e8093bfa6608c88c976c6af7..fa0175d040d6e1f2fac8e822eccdf773f6a4c620 100644
--- a/plugins/Proxy/tests/ProxyTest.php
+++ b/plugins/Proxy/tests/Unit/ProxyTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\Proxy\tests;
+namespace Piwik\Plugins\Proxy\tests\Unit;
 
 use Piwik\Plugins\Proxy\Controller;
 
diff --git a/plugins/Referrers/tests/ReferrersTest.php b/plugins/Referrers/tests/Unit/ReferrersTest.php
similarity index 100%
rename from plugins/Referrers/tests/ReferrersTest.php
rename to plugins/Referrers/tests/Unit/ReferrersTest.php
diff --git a/plugins/SEO/tests/SEOTest.php b/plugins/SEO/tests/Unit/SEOTest.php
similarity index 98%
rename from plugins/SEO/tests/SEOTest.php
rename to plugins/SEO/tests/Unit/SEOTest.php
index 06f627d2b4727c9e03a6be655f52599777208167..71cc2e341da167221cec9164dccdc6b99c2bd1ee 100644
--- a/plugins/SEO/tests/SEOTest.php
+++ b/plugins/SEO/tests/Unit/SEOTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\SEO\tests;
+namespace Piwik\Plugins\SEO\tests\Unit;
 
 use Piwik\Access;
 use Piwik\DataTable\Renderer;
diff --git a/plugins/ScheduledReports/tests/ApiTest.php b/plugins/ScheduledReports/tests/Integration/ApiTest.php
similarity index 100%
rename from plugins/ScheduledReports/tests/ApiTest.php
rename to plugins/ScheduledReports/tests/Integration/ApiTest.php
diff --git a/plugins/ScheduledReports/tests/ScheduledReportsTest.php b/plugins/ScheduledReports/tests/Integration/ScheduledReportsTest.php
similarity index 100%
rename from plugins/ScheduledReports/tests/ScheduledReportsTest.php
rename to plugins/ScheduledReports/tests/Integration/ScheduledReportsTest.php
diff --git a/plugins/SegmentEditor/tests/SegmentEditorTest.php b/plugins/SegmentEditor/tests/Integration/SegmentEditorTest.php
similarity index 99%
rename from plugins/SegmentEditor/tests/SegmentEditorTest.php
rename to plugins/SegmentEditor/tests/Integration/SegmentEditorTest.php
index 16f1b3fe34d319005f8dafbe0834a03f069c104e..3fd322b62fe552948b55e58669e4581c63e82bfe 100644
--- a/plugins/SegmentEditor/tests/SegmentEditorTest.php
+++ b/plugins/SegmentEditor/tests/Integration/SegmentEditorTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\SegmentEditor\tests;
+namespace Piwik\Plugins\SegmentEditor\tests\Integration;
 
 use Piwik\Access;
 use Piwik\Date;
diff --git a/plugins/SitesManager/tests/SiteUrlsTest.php b/plugins/SitesManager/tests/Integration/SiteUrlsTest.php
similarity index 98%
rename from plugins/SitesManager/tests/SiteUrlsTest.php
rename to plugins/SitesManager/tests/Integration/SiteUrlsTest.php
index 588b3c08f2185070b3fe71c222b2505104604a63..2ab2711c8d8cb5909c40ce939dee65bca00dd19a 100644
--- a/plugins/SitesManager/tests/SiteUrlsTest.php
+++ b/plugins/SitesManager/tests/Integration/SiteUrlsTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\SitesManager\tests;
+namespace Piwik\Plugins\SitesManager\tests\Integration;
 use Piwik\CacheFile;
 use Piwik\Plugins\SitesManager\API;
 use Piwik\Plugins\SitesManager\SiteUrls;
diff --git a/plugins/SitesManager/tests/SitesManagerTest.php b/plugins/SitesManager/tests/Integration/SitesManagerTest.php
similarity index 99%
rename from plugins/SitesManager/tests/SitesManagerTest.php
rename to plugins/SitesManager/tests/Integration/SitesManagerTest.php
index 6d08f0de2042efa90879da3151fb4a81767e4771..dc8ab0713cab205ce1e8dee02c9bf3f6f997aed7 100644
--- a/plugins/SitesManager/tests/SitesManagerTest.php
+++ b/plugins/SitesManager/tests/Integration/SitesManagerTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\SitesManager\tests;
+namespace Piwik\Plugins\SitesManager\tests\Integration;
 
 use Piwik\Access;
 use Piwik\Plugins\SitesManager\API;
diff --git a/plugins/UserCountry/tests/UserCountryTest.php b/plugins/UserCountry/tests/Unit/UserCountryTest.php
similarity index 99%
rename from plugins/UserCountry/tests/UserCountryTest.php
rename to plugins/UserCountry/tests/Unit/UserCountryTest.php
index 4dc6b9b497170d44d1e361810efd5557730a917e..540be65d70fce9d598ea3d7fee9146ee0dd796da 100644
--- a/plugins/UserCountry/tests/UserCountryTest.php
+++ b/plugins/UserCountry/tests/Unit/UserCountryTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\UserCountry\tests;
+namespace Piwik\Plugins\UserCountry\tests\Unit;
 
 use Piwik\Plugins\UserCountry\GeoIPAutoUpdater;
 use Piwik\Plugins\UserCountry\LocationProvider\GeoIp;
diff --git a/plugins/UserSettings/.gitignore b/plugins/UserSettings/.gitignore
new file mode 100644
index 0000000000000000000000000000000000000000..c8c9480010db494b8cf54ca8f9561e7a14ff51ea
--- /dev/null
+++ b/plugins/UserSettings/.gitignore
@@ -0,0 +1 @@
+tests/System/processed/*xml
\ No newline at end of file
diff --git a/plugins/UserSettings/tests/GetLanguageSystemTest.php b/plugins/UserSettings/tests/System/GetLanguageSystemTest.php
similarity index 96%
rename from plugins/UserSettings/tests/GetLanguageSystemTest.php
rename to plugins/UserSettings/tests/System/GetLanguageSystemTest.php
index e757becb1464558a5ac2be0d1c1feb53e852cf0b..cb87f88d1f8712adf60fb2191356bf13ece8f6a1 100644
--- a/plugins/UserSettings/tests/GetLanguageSystemTest.php
+++ b/plugins/UserSettings/tests/System/GetLanguageSystemTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  *
  */
-namespace Piwik\Plugins\UserSettings\tests;
+namespace Piwik\Plugins\UserSettings\tests\System;
 
 
 use Piwik\Plugins\UserSettings\tests\Fixtures\LanguageFixture;
diff --git a/plugins/UserSettings/tests/expected/test___UserSettings.getLanguageCode_day.xml b/plugins/UserSettings/tests/System/expected/test___UserSettings.getLanguageCode_day.xml
similarity index 100%
rename from plugins/UserSettings/tests/expected/test___UserSettings.getLanguageCode_day.xml
rename to plugins/UserSettings/tests/System/expected/test___UserSettings.getLanguageCode_day.xml
diff --git a/plugins/UserSettings/tests/expected/test___UserSettings.getLanguage_day.xml b/plugins/UserSettings/tests/System/expected/test___UserSettings.getLanguage_day.xml
similarity index 100%
rename from plugins/UserSettings/tests/expected/test___UserSettings.getLanguage_day.xml
rename to plugins/UserSettings/tests/System/expected/test___UserSettings.getLanguage_day.xml
diff --git a/plugins/UserSettings/tests/processed/.gitkeep b/plugins/UserSettings/tests/System/processed/.gitkeep
similarity index 100%
rename from plugins/UserSettings/tests/processed/.gitkeep
rename to plugins/UserSettings/tests/System/processed/.gitkeep
diff --git a/plugins/UserSettings/tests/processed/test___UserSettings.getLanguageCode_day.xml b/plugins/UserSettings/tests/System/processed/test___UserSettings.getLanguageCode_day.xml
similarity index 100%
rename from plugins/UserSettings/tests/processed/test___UserSettings.getLanguageCode_day.xml
rename to plugins/UserSettings/tests/System/processed/test___UserSettings.getLanguageCode_day.xml
diff --git a/plugins/UserSettings/tests/processed/test___UserSettings.getLanguage_day.xml b/plugins/UserSettings/tests/System/processed/test___UserSettings.getLanguage_day.xml
similarity index 100%
rename from plugins/UserSettings/tests/processed/test___UserSettings.getLanguage_day.xml
rename to plugins/UserSettings/tests/System/processed/test___UserSettings.getLanguage_day.xml
diff --git a/plugins/UserSettings/tests/UserSettingsTest.php b/plugins/UserSettings/tests/Unit/UserSettingsTest.php
similarity index 99%
rename from plugins/UserSettings/tests/UserSettingsTest.php
rename to plugins/UserSettings/tests/Unit/UserSettingsTest.php
index 95188a15e4b0a4d5df5b1eab28339403dc411913..408420ed6f1e817dd5ae8bb4842d3c400b635296 100644
--- a/plugins/UserSettings/tests/UserSettingsTest.php
+++ b/plugins/UserSettings/tests/Unit/UserSettingsTest.php
@@ -5,7 +5,7 @@
  * @link http://piwik.org
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
-namespace Piwik\Plugins\UserSettings\tests;
+namespace Piwik\Plugins\UserSettings\tests\Unit;
 
 use UserAgentParser;
 
diff --git a/plugins/UsersManager/tests/APITest.php b/plugins/UsersManager/tests/Integration/APITest.php
similarity index 100%
rename from plugins/UsersManager/tests/APITest.php
rename to plugins/UsersManager/tests/Integration/APITest.php
diff --git a/plugins/UsersManager/tests/UserPreferencesTest.php b/plugins/UsersManager/tests/Integration/UserPreferencesTest.php
similarity index 100%
rename from plugins/UsersManager/tests/UserPreferencesTest.php
rename to plugins/UsersManager/tests/Integration/UserPreferencesTest.php
diff --git a/plugins/UsersManager/tests/UsersManagerTest.php b/plugins/UsersManager/tests/Integration/UsersManagerTest.php
similarity index 99%
rename from plugins/UsersManager/tests/UsersManagerTest.php
rename to plugins/UsersManager/tests/Integration/UsersManagerTest.php
index da73e142d31b90f08d071990ef06b67c50ba84aa..115df6c0bb7bfc4a540685fe7ed77762ec9560fe 100644
--- a/plugins/UsersManager/tests/UsersManagerTest.php
+++ b/plugins/UsersManager/tests/Integration/UsersManagerTest.php
@@ -6,7 +6,7 @@
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  */
 
-namespace Piwik\Plugins\UsersManager\tests;
+namespace Piwik\Plugins\UsersManager\tests\Integration;
 
 use Piwik\Access;
 use Piwik\Plugins\SitesManager\API as APISitesManager;
@@ -24,6 +24,8 @@ use Exception;
  * @link http://piwik.org
  * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
  *
+ * @group UsersManagerTest
+ * @group UsersManager
  * @group Plugins
  */
 class UsersManagerTest extends IntegrationTestCase
diff --git a/tests/PHPUnit/phpunit.xml.dist b/tests/PHPUnit/phpunit.xml.dist
index 6aef96407c2685b6e9cf9b6bdfb6120711b82bf5..082591ec29c654170c871dd3bf72a348badc1ffd 100644
--- a/tests/PHPUnit/phpunit.xml.dist
+++ b/tests/PHPUnit/phpunit.xml.dist
@@ -33,17 +33,38 @@
 <testsuites>
     <testsuite name="SystemTests">
         <directory>./System</directory>
+        <directory>../../plugins/*/tests</directory><!-- There should be actually a tests/System but this way we make sure to execute all tests even if some are not moved to correct subdirectory. We will execute Unit and Integration tests twice :( ... -->
+        <directory>../../plugins/*/Test</directory>
+        <exclude>../../plugins/*/tests/Integration</exclude><!-- * in exclude is currently not supported by PHPUnit, so it won't work yet -->
+        <exclude>../../plugins/*/Test/Integration</exclude>
+        <exclude>../../plugins/*/tests/Unit</exclude>
+        <exclude>../../plugins/*/Test/Unit</exclude>
+        <exclude>../../plugins/*/tests/UI</exclude>
+        <exclude>../../plugins/*/Test/UI</exclude>
     </testsuite>
     <testsuite name="IntegrationTests">
         <directory>./Integration</directory>
-        <directory>../../plugins/*/tests</directory>
-        <directory>../../plugins/*/Test</directory>
+        <directory>../../plugins/*/tests/Integration</directory>
+        <directory>../../plugins/*/Test/Integration</directory>
     </testsuite>
     <testsuite name="UnitTests">
         <directory>./Unit</directory>
+        <directory>../../plugins/*/tests/Unit</directory>
+        <directory>../../plugins/*/Test/Unit</directory>
     </testsuite>
     <testsuite name="UITests">
         <directory>./UI</directory>
+        <directory>../../plugins/*/tests/UI</directory>
+        <directory>../../plugins/*/Test/UI</directory>
+    </testsuite>
+    <testsuite name="PluginTests">
+        <directory>../../plugins/*/tests</directory>
+        <directory>../../plugins/*/Test</directory>
+    </testsuite>
+    <testsuite name="CoreTests">
+        <directory>./Unit</directory>
+        <directory>./Integration</directory>
+        <directory>./System</directory>
     </testsuite>
 </testsuites>