From 95639bc97a3b6552831522edc516ad6c5b33d28b Mon Sep 17 00:00:00 2001
From: jpic <jamespic@gmail.com>
Date: Tue, 26 Jan 2016 02:49:21 +0100
Subject: [PATCH] Use Country.get_absolute_url in templates

Also, use django-responsediff instead of manually updating test
fixtures.
---
 ...1_paginateby12_displaylist_searchjoly.html | 188 -----------
 .../content}                                  | 289 +++++++++++-----
 .../content                                   | 287 ++++++++++++++++
 .../content}                                  | 315 ++++++++++++------
 .../content}                                  | 291 +++++++++++-----
 .../content}                                  | 269 +++++++++++----
 memopol/tests/test_representatives_list.py    |   5 +-
 setup.py                                      |   3 +-
 .../_representative_block.haml                |   3 +-
 .../representatives/representative_grid.haml  |   2 +-
 .../representatives/representative_list.haml  |   1 +
 11 files changed, 1112 insertions(+), 541 deletions(-)
 delete mode 100644 memopol/tests/RepresentativeListTest/test_page1_paginateby12_displaylist_searchjoly.html
 rename memopol/tests/{RepresentativeListTest/test_page1_paginateby12_displaylist.html => response_fixtures/RepresentativeListTest.test_page1_paginateby12_displaylist/content} (74%)
 create mode 100644 memopol/tests/response_fixtures/RepresentativeListTest.test_page1_paginateby12_displaylist_searchjoly/content
 rename memopol/tests/{RepresentativeListTest/test_page1_paginateby24_displaygrid.html => response_fixtures/RepresentativeListTest.test_page1_paginateby24_displaygrid/content} (83%)
 rename memopol/tests/{RepresentativeListTest/test_page2_paginateby12_displaylist.html => response_fixtures/RepresentativeListTest.test_page2_paginateby12_displaylist/content} (75%)
 rename memopol/tests/{RepresentativeListTest/test_page2_paginateby24_displaylist.html => response_fixtures/RepresentativeListTest.test_page2_paginateby24_displaylist/content} (74%)

diff --git a/memopol/tests/RepresentativeListTest/test_page1_paginateby12_displaylist_searchjoly.html b/memopol/tests/RepresentativeListTest/test_page1_paginateby12_displaylist_searchjoly.html
deleted file mode 100644
index 2bc1c594..00000000
--- a/memopol/tests/RepresentativeListTest/test_page1_paginateby12_displaylist_searchjoly.html
+++ /dev/null
@@ -1,188 +0,0 @@
-    <div class="container-fluid main-container">
-
-
-
-
-    <form action='' method='get'>
-      <label for='search'>
-        Search
-      </label>
-      <input id='search' type='text' name='search' />
-      <input type='submit' value='Go' />
-
-    </form>
-
-
-  <div class='pagination-block'>
-
-  <nav>
-    <ul class='pagination pagination-sm'>
-
-
-
-    </ul>
-  </nav>
-  <div class='count'>
-    Number of results : 1
-    <br />
-    Number of displayed results :
-    12
-    (
-
-      <a href='?paginate_by=12'>
-        12
-      </a>
-
-        /
-
-
-      <a href='?paginate_by=24'>
-        24
-      </a>
-
-        /
-
-
-      <a href='?paginate_by=48'>
-        48
-      </a>
-
-        /
-
-
-      <a href='?paginate_by=96'>
-        96
-      </a>
-
-
-    )
-
-      <span class='grid-list-selector'>
-  <a href='?display=grid'>
-    <i class="fa fa-th"></i>
-  </a>
-  <a href='?display=list'>
-    <i class="fa fa-th-list"></i>
-
-  </a>
-</span>
-
-
-
-  </div>
-</div>
-
-
-
-
-    <table class='table'>
-      <tr>
-        <th>
-          Photo
-        </th>
-        <th>
-          Name
-        </th>
-        <th>
-          Country
-        </th>
-        <th>
-          Group
-        </th>
-        <th>
-          Score
-
-        </th>
-      </tr>
-
-        <tr>
-          <td>
-            <a href='/legislature/representative/eva-joly/'>
-              <img src='http://www.europarl.europa.eu/mepphoto/96883.jpg' width='80' />
-
-            </a>
-          </td>
-          <td>
-            <a href='/legislature/representative/eva-joly/'>
-              Eva JOLY
-
-            </a>
-          </td>
-          <td>
-              France [FR]
-
-          </td>
-          <td>
-            <a href='/legislature/representative/group/Group%20of%20the%20Greens/European%20Free%20Alliance/'>
-              Greens/EFA
-            </a>
-          </td>
-          <td>
-            <span class="label label-success">15</span>
-
-          </td>
-        </tr>
-
-    </table>
-
-
-  <div class='pagination-block'>
-
-  <nav>
-    <ul class='pagination pagination-sm'>
-
-
-
-    </ul>
-  </nav>
-  <div class='count'>
-    Number of results : 1
-    <br />
-    Number of displayed results :
-    12
-    (
-
-      <a href='?paginate_by=12'>
-        12
-      </a>
-
-        /
-
-
-      <a href='?paginate_by=24'>
-        24
-      </a>
-
-        /
-
-
-      <a href='?paginate_by=48'>
-        48
-      </a>
-
-        /
-
-
-      <a href='?paginate_by=96'>
-        96
-      </a>
-
-
-    )
-
-      <span class='grid-list-selector'>
-  <a href='?display=grid'>
-    <i class="fa fa-th"></i>
-  </a>
-  <a href='?display=list'>
-    <i class="fa fa-th-list"></i>
-
-  </a>
-</span>
-
-
-
-  </div>
-</div>
-
-
diff --git a/memopol/tests/RepresentativeListTest/test_page1_paginateby12_displaylist.html b/memopol/tests/response_fixtures/RepresentativeListTest.test_page1_paginateby12_displaylist/content
similarity index 74%
rename from memopol/tests/RepresentativeListTest/test_page1_paginateby12_displaylist.html
rename to memopol/tests/response_fixtures/RepresentativeListTest.test_page1_paginateby12_displaylist/content
index 062f0678..52bc5472 100644
--- a/memopol/tests/RepresentativeListTest/test_page1_paginateby12_displaylist.html
+++ b/memopol/tests/response_fixtures/RepresentativeListTest.test_page1_paginateby12_displaylist/content
@@ -1,7 +1,80 @@
-    <div class="container-fluid main-container">
+<!DOCTYPE html>
+<html class="no-js" lang="en"> <!--<![endif]-->
+  <head>
+    <meta charset="utf-8" />
+    <link rel="icon" type="image/png" href="/static/collected/img/favicon.ico" />
+    <!-- Set the viewport width to device width for mobile -->
+    <meta name="viewport" content="width=device-width" />
+    <title>
+      Home
+      - The Political Memory of </title>
+    
+    
+    <link rel="stylesheet" href="/static/collected/libs/bootstrap/dist/css/bootstrap.min.css" type="text/css" /><link rel="stylesheet" href="/static/collected/libs/fontawesome/css/font-awesome.min.css" type="text/css" /><link rel="stylesheet" href="/static/collected/libs/flag-icon-css/css/flag-icon.min.css" type="text/css" /><link rel="stylesheet" href="/static/collected/CACHE/css/base.53baf9815401.css" type="text/css" />
+    <script type="text/javascript" src="/static/collected/libs/jquery/dist/jquery.js"></script>
+<script type="text/javascript" src="/static/collected/libs/bootstrap/dist/js/bootstrap.js"></script>
+    
+  </head>
+  <body >
+    <!-- -load memopol_tags cache -->
+
+
+
+
+<div id='header' class='container-fluid'>
+  <a id='logo' href='/'>
+    <img src='/static/collected/images/logo.png' />
+  </a>
+  <h1>
+    <a id='header_banner' href='/'>
+      Political Memory
+    </a>
+  </h1>
+  <p class='organization'>
+    
+
+  </p>
+</div>
+<div id='nav' class='container-fluid'>
+  <ul class='nav'>
+    <li>
+      <a href='/legislature/representative/'>
+        Representatives
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/country/'>
+        Countries
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/group/'>
+        Parties
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/delegation/'>
+        Delegations
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/committee/'>
+        Committees
+      </a>
+    </li>
+    <li>
+      <a href='/votes/dossier/'>
+        Votes
 
+      </a>
+    </li>
+  </ul>
+</div>
 
+    <div class="container-fluid main-container">
+      
 
+  
 
     <form action='' method='get'>
       <label for='search'>
@@ -11,47 +84,47 @@
       <input type='submit' value='Go' />
 
     </form>
-
+  
 
   <div class='pagination-block'>
 
   <nav>
     <ul class='pagination pagination-sm'>
-
-
-
-
+      
+      
+        
+          
             <li class='active'>
               <a href=''>
                 1
               </a>
             </li>
-
-
-
-
-
+          
+        
+      
+        
+          
             <li>
               <a href='?&page=2'>
                 2
 
               </a>
             </li>
-
-
-
-
-
+          
+        
+      
+        
+          
             <li>
               <a href='?&page=3'>
                 3
 
               </a>
             </li>
-
-
-
-
+          
+        
+      
+      
         <li>
           <a aria-label='Next' href='?&page=2'>
             <i aria-hidden="true" class="fa fa-chevron-right"></i>
@@ -64,7 +137,7 @@
 
           </a>
         </li>
-
+      
     </ul>
   </nav>
   <div class='count'>
@@ -73,35 +146,35 @@
     Number of displayed results :
     12
     (
-
+    
       <a href='?paginate_by=12'>
         12
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=24'>
         24
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=48'>
         48
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=96'>
         96
       </a>
-
-
+      
+    
     )
-
+    
       <span class='grid-list-selector'>
   <a href='?display=grid'>
     <i class="fa fa-th"></i>
@@ -113,12 +186,12 @@
 </span>
 
 
-
+    
   </div>
 </div>
 
 
-
+  
 
     <table class='table'>
       <tr>
@@ -139,7 +212,7 @@
 
         </th>
       </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/zigmantas-balcytis/'>
@@ -154,8 +227,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Lithuania/'>
               Lithuania [LT]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Progressive%20Alliance%20of%20Socialists%20and%20Democrats%20in%20the%20European%20Parliament/'>
@@ -167,7 +242,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/vilija-blinkeviciute/'>
@@ -182,8 +257,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Lithuania/'>
               Lithuania [LT]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Progressive%20Alliance%20of%20Socialists%20and%20Democrats%20in%20the%20European%20Parliament/'>
@@ -195,7 +272,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/elmar-brok/'>
@@ -210,8 +287,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Germany/'>
               Germany [DE]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20European%20People&#39;s%20Party%20(Christian%20Democrats)/'>
@@ -223,7 +302,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/cristian-silviu-busoi/'>
@@ -238,8 +317,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Romania/'>
               Romania [RO]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20European%20People&#39;s%20Party%20(Christian%20Democrats)/'>
@@ -251,7 +332,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/david-casa/'>
@@ -266,8 +347,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Malta/'>
               Malta [MT]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20European%20People&#39;s%20Party%20(Christian%20Democrats)/'>
@@ -279,7 +362,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/jean-marie-cavada/'>
@@ -294,8 +377,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/France/'>
               France [FR]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Alliance%20of%20Liberals%20and%20Democrats%20for%20Europe/'>
@@ -307,7 +392,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/nikolaos-chountis/'>
@@ -322,8 +407,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Greece/'>
               Greece [GR]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Confederal%20Group%20of%20the%20European%20United%20Left%20-%20Nordic%20Green%20Left/'>
@@ -335,7 +422,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/michael-cramer/'>
@@ -350,8 +437,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Germany/'>
               Germany [DE]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Greens/European%20Free%20Alliance/'>
@@ -363,7 +452,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/michel-dantin/'>
@@ -378,8 +467,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/France/'>
               France [FR]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20European%20People&#39;s%20Party%20(Christian%20Democrats)/'>
@@ -391,7 +482,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/tamas-deutsch/'>
@@ -406,8 +497,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Hungary/'>
               Hungary [HU]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20European%20People&#39;s%20Party%20(Christian%20Democrats)/'>
@@ -419,7 +512,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/viorica-dancila/'>
@@ -434,8 +527,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Romania/'>
               Romania [RO]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Progressive%20Alliance%20of%20Socialists%20and%20Democrats%20in%20the%20European%20Parliament/'>
@@ -447,7 +542,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/bas-eickhout/'>
@@ -462,8 +557,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Netherlands/'>
               Netherlands [NL]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Greens/European%20Free%20Alliance/'>
@@ -475,49 +572,49 @@
 
           </td>
         </tr>
-
+      
     </table>
-
+  
 
   <div class='pagination-block'>
 
   <nav>
     <ul class='pagination pagination-sm'>
-
-
-
-
+      
+      
+        
+          
             <li class='active'>
               <a href=''>
                 1
               </a>
             </li>
-
-
-
-
-
+          
+        
+      
+        
+          
             <li>
               <a href='?&page=2'>
                 2
 
               </a>
             </li>
-
-
-
-
-
+          
+        
+      
+        
+          
             <li>
               <a href='?&page=3'>
                 3
 
               </a>
             </li>
-
-
-
-
+          
+        
+      
+      
         <li>
           <a aria-label='Next' href='?&page=2'>
             <i aria-hidden="true" class="fa fa-chevron-right"></i>
@@ -530,7 +627,7 @@
 
           </a>
         </li>
-
+      
     </ul>
   </nav>
   <div class='count'>
@@ -539,35 +636,35 @@
     Number of displayed results :
     12
     (
-
+    
       <a href='?paginate_by=12'>
         12
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=24'>
         24
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=48'>
         48
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=96'>
         96
       </a>
-
-
+      
+    
     )
-
+    
       <span class='grid-list-selector'>
   <a href='?display=grid'>
     <i class="fa fa-th"></i>
@@ -579,6 +676,32 @@
 </span>
 
 
-
+    
   </div>
 </div>
+
+
+
+    </div>
+    
+
+<div id='footer' class='container-fluid'>
+  
+    Memopol is free software
+    <a href="https://gitorious.org/memopol2-0">released</a>
+    under the terms of the
+    <a href="http://www.gnu.org/licenses/agpl.html">GNU aGPLV3+</a>
+  
+  <a href='https://projets.lqdn.fr/projects/mempol'>
+    Bug tracking system
+  </a>
+  <a href='https://projets.lqdn.fr/projects/mempol/issues/new'>
+    Report a bug
+  </a>
+  <br />
+  Provided by <a href="http://www.laquadrature.net/">La Quadrature du Net</a>
+
+</div>
+
+  </body>
+</html>
diff --git a/memopol/tests/response_fixtures/RepresentativeListTest.test_page1_paginateby12_displaylist_searchjoly/content b/memopol/tests/response_fixtures/RepresentativeListTest.test_page1_paginateby12_displaylist_searchjoly/content
new file mode 100644
index 00000000..d88608d7
--- /dev/null
+++ b/memopol/tests/response_fixtures/RepresentativeListTest.test_page1_paginateby12_displaylist_searchjoly/content
@@ -0,0 +1,287 @@
+<!DOCTYPE html>
+<html class="no-js" lang="en"> <!--<![endif]-->
+  <head>
+    <meta charset="utf-8" />
+    <link rel="icon" type="image/png" href="/static/collected/img/favicon.ico" />
+    <!-- Set the viewport width to device width for mobile -->
+    <meta name="viewport" content="width=device-width" />
+    <title>
+      Home
+      - The Political Memory of </title>
+    
+    
+    <link rel="stylesheet" href="/static/collected/libs/bootstrap/dist/css/bootstrap.min.css" type="text/css" /><link rel="stylesheet" href="/static/collected/libs/fontawesome/css/font-awesome.min.css" type="text/css" /><link rel="stylesheet" href="/static/collected/libs/flag-icon-css/css/flag-icon.min.css" type="text/css" /><link rel="stylesheet" href="/static/collected/CACHE/css/base.53baf9815401.css" type="text/css" />
+    <script type="text/javascript" src="/static/collected/libs/jquery/dist/jquery.js"></script>
+<script type="text/javascript" src="/static/collected/libs/bootstrap/dist/js/bootstrap.js"></script>
+    
+  </head>
+  <body >
+    <!-- -load memopol_tags cache -->
+
+
+
+
+<div id='header' class='container-fluid'>
+  <a id='logo' href='/'>
+    <img src='/static/collected/images/logo.png' />
+  </a>
+  <h1>
+    <a id='header_banner' href='/'>
+      Political Memory
+    </a>
+  </h1>
+  <p class='organization'>
+    
+
+  </p>
+</div>
+<div id='nav' class='container-fluid'>
+  <ul class='nav'>
+    <li>
+      <a href='/legislature/representative/'>
+        Representatives
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/country/'>
+        Countries
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/group/'>
+        Parties
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/delegation/'>
+        Delegations
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/committee/'>
+        Committees
+      </a>
+    </li>
+    <li>
+      <a href='/votes/dossier/'>
+        Votes
+
+      </a>
+    </li>
+  </ul>
+</div>
+
+    <div class="container-fluid main-container">
+      
+
+  
+
+    <form action='' method='get'>
+      <label for='search'>
+        Search
+      </label>
+      <input id='search' type='text' name='search' />
+      <input type='submit' value='Go' />
+
+    </form>
+  
+
+  <div class='pagination-block'>
+
+  <nav>
+    <ul class='pagination pagination-sm'>
+      
+      
+      
+    </ul>
+  </nav>
+  <div class='count'>
+    Number of results : 1
+    <br />
+    Number of displayed results :
+    12
+    (
+    
+      <a href='?paginate_by=12'>
+        12
+      </a>
+      
+        /
+      
+    
+      <a href='?paginate_by=24'>
+        24
+      </a>
+      
+        /
+      
+    
+      <a href='?paginate_by=48'>
+        48
+      </a>
+      
+        /
+      
+    
+      <a href='?paginate_by=96'>
+        96
+      </a>
+      
+    
+    )
+    
+      <span class='grid-list-selector'>
+  <a href='?display=grid'>
+    <i class="fa fa-th"></i>
+  </a>
+  <a href='?display=list'>
+    <i class="fa fa-th-list"></i>
+
+  </a>
+</span>
+
+
+    
+  </div>
+</div>
+
+
+  
+
+    <table class='table'>
+      <tr>
+        <th>
+          Photo
+        </th>
+        <th>
+          Name
+        </th>
+        <th>
+          Country
+        </th>
+        <th>
+          Group
+        </th>
+        <th>
+          Score
+
+        </th>
+      </tr>
+      
+        <tr>
+          <td>
+            <a href='/legislature/representative/eva-joly/'>
+              <img src='http://www.europarl.europa.eu/mepphoto/96883.jpg' width='80' />
+
+            </a>
+          </td>
+          <td>
+            <a href='/legislature/representative/eva-joly/'>
+              Eva JOLY
+
+            </a>
+          </td>
+          <td>
+            <a href='/legislature/representative/country/France/'>
+              France [FR]
+
+            </a>
+          </td>
+          <td>
+            <a href='/legislature/representative/group/Group%20of%20the%20Greens/European%20Free%20Alliance/'>
+              Greens/EFA
+            </a>
+          </td>
+          <td>
+            <span class="label label-success">15</span>
+
+          </td>
+        </tr>
+      
+    </table>
+  
+
+  <div class='pagination-block'>
+
+  <nav>
+    <ul class='pagination pagination-sm'>
+      
+      
+      
+    </ul>
+  </nav>
+  <div class='count'>
+    Number of results : 1
+    <br />
+    Number of displayed results :
+    12
+    (
+    
+      <a href='?paginate_by=12'>
+        12
+      </a>
+      
+        /
+      
+    
+      <a href='?paginate_by=24'>
+        24
+      </a>
+      
+        /
+      
+    
+      <a href='?paginate_by=48'>
+        48
+      </a>
+      
+        /
+      
+    
+      <a href='?paginate_by=96'>
+        96
+      </a>
+      
+    
+    )
+    
+      <span class='grid-list-selector'>
+  <a href='?display=grid'>
+    <i class="fa fa-th"></i>
+  </a>
+  <a href='?display=list'>
+    <i class="fa fa-th-list"></i>
+
+  </a>
+</span>
+
+
+    
+  </div>
+</div>
+
+
+
+    </div>
+    
+
+<div id='footer' class='container-fluid'>
+  
+    Memopol is free software
+    <a href="https://gitorious.org/memopol2-0">released</a>
+    under the terms of the
+    <a href="http://www.gnu.org/licenses/agpl.html">GNU aGPLV3+</a>
+  
+  <a href='https://projets.lqdn.fr/projects/mempol'>
+    Bug tracking system
+  </a>
+  <a href='https://projets.lqdn.fr/projects/mempol/issues/new'>
+    Report a bug
+  </a>
+  <br />
+  Provided by <a href="http://www.laquadrature.net/">La Quadrature du Net</a>
+
+</div>
+
+  </body>
+</html>
diff --git a/memopol/tests/RepresentativeListTest/test_page1_paginateby24_displaygrid.html b/memopol/tests/response_fixtures/RepresentativeListTest.test_page1_paginateby24_displaygrid/content
similarity index 83%
rename from memopol/tests/RepresentativeListTest/test_page1_paginateby24_displaygrid.html
rename to memopol/tests/response_fixtures/RepresentativeListTest.test_page1_paginateby24_displaygrid/content
index 08428922..5f0203ce 100644
--- a/memopol/tests/RepresentativeListTest/test_page1_paginateby24_displaygrid.html
+++ b/memopol/tests/response_fixtures/RepresentativeListTest.test_page1_paginateby24_displaygrid/content
@@ -1,7 +1,80 @@
-    <div class="container-fluid main-container">
+<!DOCTYPE html>
+<html class="no-js" lang="en"> <!--<![endif]-->
+  <head>
+    <meta charset="utf-8" />
+    <link rel="icon" type="image/png" href="/static/collected/img/favicon.ico" />
+    <!-- Set the viewport width to device width for mobile -->
+    <meta name="viewport" content="width=device-width" />
+    <title>
+      Home
+      - The Political Memory of </title>
+    
+    
+    <link rel="stylesheet" href="/static/collected/libs/bootstrap/dist/css/bootstrap.min.css" type="text/css" /><link rel="stylesheet" href="/static/collected/libs/fontawesome/css/font-awesome.min.css" type="text/css" /><link rel="stylesheet" href="/static/collected/libs/flag-icon-css/css/flag-icon.min.css" type="text/css" /><link rel="stylesheet" href="/static/collected/CACHE/css/base.53baf9815401.css" type="text/css" />
+    <script type="text/javascript" src="/static/collected/libs/jquery/dist/jquery.js"></script>
+<script type="text/javascript" src="/static/collected/libs/bootstrap/dist/js/bootstrap.js"></script>
+    
+  </head>
+  <body >
+    <!-- -load memopol_tags cache -->
+
+
+
+
+<div id='header' class='container-fluid'>
+  <a id='logo' href='/'>
+    <img src='/static/collected/images/logo.png' />
+  </a>
+  <h1>
+    <a id='header_banner' href='/'>
+      Political Memory
+    </a>
+  </h1>
+  <p class='organization'>
+    
+
+  </p>
+</div>
+<div id='nav' class='container-fluid'>
+  <ul class='nav'>
+    <li>
+      <a href='/legislature/representative/'>
+        Representatives
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/country/'>
+        Countries
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/group/'>
+        Parties
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/delegation/'>
+        Delegations
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/committee/'>
+        Committees
+      </a>
+    </li>
+    <li>
+      <a href='/votes/dossier/'>
+        Votes
 
+      </a>
+    </li>
+  </ul>
+</div>
 
+    <div class="container-fluid main-container">
+      
 
+  
 
     <form action='' method='get'>
       <label for='search'>
@@ -11,36 +84,36 @@
       <input type='submit' value='Go' />
 
     </form>
-
+  
 
   <div class='pagination-block'>
 
   <nav>
     <ul class='pagination pagination-sm'>
-
-
-
-
+      
+      
+        
+          
             <li class='active'>
               <a href=''>
                 1
               </a>
             </li>
-
-
-
-
-
+          
+        
+      
+        
+          
             <li>
               <a href='?&page=2'>
                 2
 
               </a>
             </li>
-
-
-
-
+          
+        
+      
+      
         <li>
           <a aria-label='Next' href='?&page=2'>
             <i aria-hidden="true" class="fa fa-chevron-right"></i>
@@ -53,7 +126,7 @@
 
           </a>
         </li>
-
+      
     </ul>
   </nav>
   <div class='count'>
@@ -62,35 +135,35 @@
     Number of displayed results :
     24
     (
-
+    
       <a href='?paginate_by=12'>
         12
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=24'>
         24
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=48'>
         48
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=96'>
         96
       </a>
-
-
+      
+    
     )
-
+    
       <span class='grid-list-selector'>
   <a href='?display=grid'>
     <i class="fa fa-th"></i>
@@ -102,15 +175,15 @@
 </span>
 
 
-
+    
   </div>
 </div>
 
 
-
+  
 
   <div class='representative_grid'>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/zigmantas-balcytis/'>
@@ -124,7 +197,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/LT/'>
+            <a href='/legislature/representative/country/Lithuania/'>
               <span class="flag-icon flag-icon-lt"></span> Lithuania
             </a>
           </li>
@@ -139,7 +212,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/vilija-blinkeviciute/'>
@@ -153,7 +226,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/LT/'>
+            <a href='/legislature/representative/country/Lithuania/'>
               <span class="flag-icon flag-icon-lt"></span> Lithuania
             </a>
           </li>
@@ -168,7 +241,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/elmar-brok/'>
@@ -182,7 +255,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/DE/'>
+            <a href='/legislature/representative/country/Germany/'>
               <span class="flag-icon flag-icon-de"></span> Germany
             </a>
           </li>
@@ -197,7 +270,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/cristian-silviu-busoi/'>
@@ -211,7 +284,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/RO/'>
+            <a href='/legislature/representative/country/Romania/'>
               <span class="flag-icon flag-icon-ro"></span> Romania
             </a>
           </li>
@@ -226,7 +299,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/david-casa/'>
@@ -240,7 +313,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/MT/'>
+            <a href='/legislature/representative/country/Malta/'>
               <span class="flag-icon flag-icon-mt"></span> Malta
             </a>
           </li>
@@ -255,7 +328,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/jean-marie-cavada/'>
@@ -269,7 +342,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/FR/'>
+            <a href='/legislature/representative/country/France/'>
               <span class="flag-icon flag-icon-fr"></span> France
             </a>
           </li>
@@ -284,7 +357,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/nikolaos-chountis/'>
@@ -298,7 +371,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/GR/'>
+            <a href='/legislature/representative/country/Greece/'>
               <span class="flag-icon flag-icon-gr"></span> Greece
             </a>
           </li>
@@ -313,7 +386,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/michael-cramer/'>
@@ -327,7 +400,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/DE/'>
+            <a href='/legislature/representative/country/Germany/'>
               <span class="flag-icon flag-icon-de"></span> Germany
             </a>
           </li>
@@ -342,7 +415,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/michel-dantin/'>
@@ -356,7 +429,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/FR/'>
+            <a href='/legislature/representative/country/France/'>
               <span class="flag-icon flag-icon-fr"></span> France
             </a>
           </li>
@@ -371,7 +444,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/tamas-deutsch/'>
@@ -385,7 +458,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/HU/'>
+            <a href='/legislature/representative/country/Hungary/'>
               <span class="flag-icon flag-icon-hu"></span> Hungary
             </a>
           </li>
@@ -400,7 +473,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/viorica-dancila/'>
@@ -414,7 +487,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/RO/'>
+            <a href='/legislature/representative/country/Romania/'>
               <span class="flag-icon flag-icon-ro"></span> Romania
             </a>
           </li>
@@ -429,7 +502,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/bas-eickhout/'>
@@ -443,7 +516,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/NL/'>
+            <a href='/legislature/representative/country/Netherlands/'>
               <span class="flag-icon flag-icon-nl"></span> Netherlands
             </a>
           </li>
@@ -458,7 +531,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/ismail-ertug/'>
@@ -472,7 +545,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/DE/'>
+            <a href='/legislature/representative/country/Germany/'>
               <span class="flag-icon flag-icon-de"></span> Germany
             </a>
           </li>
@@ -487,7 +560,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/jose-manuel-fernandes/'>
@@ -501,7 +574,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/PT/'>
+            <a href='/legislature/representative/country/Portugal/'>
               <span class="flag-icon flag-icon-pt"></span> Portugal
             </a>
           </li>
@@ -516,7 +589,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/monika-flasikova-benova/'>
@@ -530,7 +603,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/SK/'>
+            <a href='/legislature/representative/country/Slovakia/'>
               <span class="flag-icon flag-icon-sk"></span> Slovakia
             </a>
           </li>
@@ -545,7 +618,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/ashley-fox/'>
@@ -559,7 +632,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/GB/'>
+            <a href='/legislature/representative/country/United%20Kingdom/'>
               <span class="flag-icon flag-icon-gb"></span> United Kingdom
             </a>
           </li>
@@ -574,7 +647,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/eider-gardiazabal-rubial/'>
@@ -588,7 +661,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/ES/'>
+            <a href='/legislature/representative/country/Spain/'>
               <span class="flag-icon flag-icon-es"></span> Spain
             </a>
           </li>
@@ -603,7 +676,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/kinga-gal/'>
@@ -617,7 +690,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/HU/'>
+            <a href='/legislature/representative/country/Hungary/'>
               <span class="flag-icon flag-icon-hu"></span> Hungary
             </a>
           </li>
@@ -632,7 +705,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/ildiko-gall-pelcz/'>
@@ -646,7 +719,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/HU/'>
+            <a href='/legislature/representative/country/Hungary/'>
               <span class="flag-icon flag-icon-hu"></span> Hungary
             </a>
           </li>
@@ -661,7 +734,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/marian-harkin/'>
@@ -675,7 +748,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/IE/'>
+            <a href='/legislature/representative/country/Ireland/'>
               <span class="flag-icon flag-icon-ie"></span> Ireland
             </a>
           </li>
@@ -690,7 +763,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/mary-honeyball/'>
@@ -704,7 +777,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/GB/'>
+            <a href='/legislature/representative/country/United%20Kingdom/'>
               <span class="flag-icon flag-icon-gb"></span> United Kingdom
             </a>
           </li>
@@ -719,7 +792,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/iliana-iotova/'>
@@ -733,7 +806,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/BG/'>
+            <a href='/legislature/representative/country/Bulgaria/'>
               <span class="flag-icon flag-icon-bg"></span> Bulgaria
             </a>
           </li>
@@ -748,7 +821,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/liisa-jaakonsaari/'>
@@ -762,7 +835,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/FI/'>
+            <a href='/legislature/representative/country/Finland/'>
               <span class="flag-icon flag-icon-fi"></span> Finland
             </a>
           </li>
@@ -777,7 +850,7 @@
           </li>
         </ul>
       </div>
-
+    
       <div class='representative_item'>
         <p class='photo'>
           <a href='/legislature/representative/yannick-jadot/'>
@@ -791,7 +864,7 @@
             </a>
           </li>
           <li class='country'>
-            <a href='/legislature/representative/country/FR/'>
+            <a href='/legislature/representative/country/France/'>
               <span class="flag-icon flag-icon-fr"></span> France
             </a>
           </li>
@@ -806,7 +879,7 @@
           </li>
         </ul>
       </div>
-
+    
   </div>
 
 
@@ -814,30 +887,30 @@
 
   <nav>
     <ul class='pagination pagination-sm'>
-
-
-
-
+      
+      
+        
+          
             <li class='active'>
               <a href=''>
                 1
               </a>
             </li>
-
-
-
-
-
+          
+        
+      
+        
+          
             <li>
               <a href='?&page=2'>
                 2
 
               </a>
             </li>
-
-
-
-
+          
+        
+      
+      
         <li>
           <a aria-label='Next' href='?&page=2'>
             <i aria-hidden="true" class="fa fa-chevron-right"></i>
@@ -850,7 +923,7 @@
 
           </a>
         </li>
-
+      
     </ul>
   </nav>
   <div class='count'>
@@ -859,35 +932,35 @@
     Number of displayed results :
     24
     (
-
+    
       <a href='?paginate_by=12'>
         12
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=24'>
         24
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=48'>
         48
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=96'>
         96
       </a>
-
-
+      
+    
     )
-
+    
       <span class='grid-list-selector'>
   <a href='?display=grid'>
     <i class="fa fa-th"></i>
@@ -899,6 +972,32 @@
 </span>
 
 
-
+    
   </div>
 </div>
+
+
+
+    </div>
+    
+
+<div id='footer' class='container-fluid'>
+  
+    Memopol is free software
+    <a href="https://gitorious.org/memopol2-0">released</a>
+    under the terms of the
+    <a href="http://www.gnu.org/licenses/agpl.html">GNU aGPLV3+</a>
+  
+  <a href='https://projets.lqdn.fr/projects/mempol'>
+    Bug tracking system
+  </a>
+  <a href='https://projets.lqdn.fr/projects/mempol/issues/new'>
+    Report a bug
+  </a>
+  <br />
+  Provided by <a href="http://www.laquadrature.net/">La Quadrature du Net</a>
+
+</div>
+
+  </body>
+</html>
diff --git a/memopol/tests/RepresentativeListTest/test_page2_paginateby12_displaylist.html b/memopol/tests/response_fixtures/RepresentativeListTest.test_page2_paginateby12_displaylist/content
similarity index 75%
rename from memopol/tests/RepresentativeListTest/test_page2_paginateby12_displaylist.html
rename to memopol/tests/response_fixtures/RepresentativeListTest.test_page2_paginateby12_displaylist/content
index 4f59ddf5..97372153 100644
--- a/memopol/tests/RepresentativeListTest/test_page2_paginateby12_displaylist.html
+++ b/memopol/tests/response_fixtures/RepresentativeListTest.test_page2_paginateby12_displaylist/content
@@ -1,7 +1,80 @@
-    <div class="container-fluid main-container">
+<!DOCTYPE html>
+<html class="no-js" lang="en"> <!--<![endif]-->
+  <head>
+    <meta charset="utf-8" />
+    <link rel="icon" type="image/png" href="/static/collected/img/favicon.ico" />
+    <!-- Set the viewport width to device width for mobile -->
+    <meta name="viewport" content="width=device-width" />
+    <title>
+      Home
+      - The Political Memory of </title>
+    
+    
+    <link rel="stylesheet" href="/static/collected/libs/bootstrap/dist/css/bootstrap.min.css" type="text/css" /><link rel="stylesheet" href="/static/collected/libs/fontawesome/css/font-awesome.min.css" type="text/css" /><link rel="stylesheet" href="/static/collected/libs/flag-icon-css/css/flag-icon.min.css" type="text/css" /><link rel="stylesheet" href="/static/collected/CACHE/css/base.53baf9815401.css" type="text/css" />
+    <script type="text/javascript" src="/static/collected/libs/jquery/dist/jquery.js"></script>
+<script type="text/javascript" src="/static/collected/libs/bootstrap/dist/js/bootstrap.js"></script>
+    
+  </head>
+  <body >
+    <!-- -load memopol_tags cache -->
+
+
+
+
+<div id='header' class='container-fluid'>
+  <a id='logo' href='/'>
+    <img src='/static/collected/images/logo.png' />
+  </a>
+  <h1>
+    <a id='header_banner' href='/'>
+      Political Memory
+    </a>
+  </h1>
+  <p class='organization'>
+    
+
+  </p>
+</div>
+<div id='nav' class='container-fluid'>
+  <ul class='nav'>
+    <li>
+      <a href='/legislature/representative/'>
+        Representatives
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/country/'>
+        Countries
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/group/'>
+        Parties
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/delegation/'>
+        Delegations
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/committee/'>
+        Committees
+      </a>
+    </li>
+    <li>
+      <a href='/votes/dossier/'>
+        Votes
 
+      </a>
+    </li>
+  </ul>
+</div>
 
+    <div class="container-fluid main-container">
+      
 
+  
 
     <form action='' method='get'>
       <label for='search'>
@@ -11,13 +84,13 @@
       <input type='submit' value='Go' />
 
     </form>
-
+  
 
   <div class='pagination-block'>
 
   <nav>
     <ul class='pagination pagination-sm'>
-
+      
         <li>
           <a aria-label='First' href='?&page=1'>
             <i aria-hidden="true" class="fa fa-chevron-circle-left"></i>
@@ -30,41 +103,41 @@
 
           </a>
         </li>
-
-
-
-
+      
+      
+        
+          
             <li>
               <a href='?&page=1'>
                 1
 
               </a>
             </li>
-
-
-
-
-
+          
+        
+      
+        
+          
             <li class='active'>
               <a href=''>
                 2
               </a>
             </li>
-
-
-
-
-
+          
+        
+      
+        
+          
             <li>
               <a href='?&page=3'>
                 3
 
               </a>
             </li>
-
-
-
-
+          
+        
+      
+      
         <li>
           <a aria-label='Next' href='?&page=3'>
             <i aria-hidden="true" class="fa fa-chevron-right"></i>
@@ -77,7 +150,7 @@
 
           </a>
         </li>
-
+      
     </ul>
   </nav>
   <div class='count'>
@@ -86,35 +159,35 @@
     Number of displayed results :
     12
     (
-
+    
       <a href='?paginate_by=12'>
         12
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=24'>
         24
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=48'>
         48
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=96'>
         96
       </a>
-
-
+      
+    
     )
-
+    
       <span class='grid-list-selector'>
   <a href='?display=grid'>
     <i class="fa fa-th"></i>
@@ -126,12 +199,12 @@
 </span>
 
 
-
+    
   </div>
 </div>
 
 
-
+  
 
     <table class='table'>
       <tr>
@@ -152,7 +225,7 @@
 
         </th>
       </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/ismail-ertug/'>
@@ -167,8 +240,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Germany/'>
               Germany [DE]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Progressive%20Alliance%20of%20Socialists%20and%20Democrats%20in%20the%20European%20Parliament/'>
@@ -180,7 +255,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/jose-manuel-fernandes/'>
@@ -195,8 +270,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Portugal/'>
               Portugal [PT]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20European%20People&#39;s%20Party%20(Christian%20Democrats)/'>
@@ -208,7 +285,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/monika-flasikova-benova/'>
@@ -223,8 +300,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Slovakia/'>
               Slovakia [SK]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Progressive%20Alliance%20of%20Socialists%20and%20Democrats%20in%20the%20European%20Parliament/'>
@@ -236,7 +315,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/ashley-fox/'>
@@ -251,8 +330,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/United%20Kingdom/'>
               United Kingdom [GB]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/European%20Conservatives%20and%20Reformists%20Group/'>
@@ -264,7 +345,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/eider-gardiazabal-rubial/'>
@@ -279,8 +360,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Spain/'>
               Spain [ES]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Progressive%20Alliance%20of%20Socialists%20and%20Democrats%20in%20the%20European%20Parliament/'>
@@ -292,7 +375,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/kinga-gal/'>
@@ -307,8 +390,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Hungary/'>
               Hungary [HU]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20European%20People&#39;s%20Party%20(Christian%20Democrats)/'>
@@ -320,7 +405,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/ildiko-gall-pelcz/'>
@@ -335,8 +420,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Hungary/'>
               Hungary [HU]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20European%20People&#39;s%20Party%20(Christian%20Democrats)/'>
@@ -348,7 +435,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/marian-harkin/'>
@@ -363,8 +450,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Ireland/'>
               Ireland [IE]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Alliance%20of%20Liberals%20and%20Democrats%20for%20Europe/'>
@@ -376,7 +465,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/mary-honeyball/'>
@@ -391,8 +480,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/United%20Kingdom/'>
               United Kingdom [GB]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Progressive%20Alliance%20of%20Socialists%20and%20Democrats%20in%20the%20European%20Parliament/'>
@@ -404,7 +495,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/iliana-iotova/'>
@@ -419,8 +510,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Bulgaria/'>
               Bulgaria [BG]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Progressive%20Alliance%20of%20Socialists%20and%20Democrats%20in%20the%20European%20Parliament/'>
@@ -432,7 +525,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/liisa-jaakonsaari/'>
@@ -447,8 +540,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Finland/'>
               Finland [FI]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Progressive%20Alliance%20of%20Socialists%20and%20Democrats%20in%20the%20European%20Parliament/'>
@@ -460,7 +555,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/yannick-jadot/'>
@@ -475,8 +570,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/France/'>
               France [FR]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Greens/European%20Free%20Alliance/'>
@@ -488,15 +585,15 @@
 
           </td>
         </tr>
-
+      
     </table>
-
+  
 
   <div class='pagination-block'>
 
   <nav>
     <ul class='pagination pagination-sm'>
-
+      
         <li>
           <a aria-label='First' href='?&page=1'>
             <i aria-hidden="true" class="fa fa-chevron-circle-left"></i>
@@ -509,41 +606,41 @@
 
           </a>
         </li>
-
-
-
-
+      
+      
+        
+          
             <li>
               <a href='?&page=1'>
                 1
 
               </a>
             </li>
-
-
-
-
-
+          
+        
+      
+        
+          
             <li class='active'>
               <a href=''>
                 2
               </a>
             </li>
-
-
-
-
-
+          
+        
+      
+        
+          
             <li>
               <a href='?&page=3'>
                 3
 
               </a>
             </li>
-
-
-
-
+          
+        
+      
+      
         <li>
           <a aria-label='Next' href='?&page=3'>
             <i aria-hidden="true" class="fa fa-chevron-right"></i>
@@ -556,7 +653,7 @@
 
           </a>
         </li>
-
+      
     </ul>
   </nav>
   <div class='count'>
@@ -565,35 +662,35 @@
     Number of displayed results :
     12
     (
-
+    
       <a href='?paginate_by=12'>
         12
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=24'>
         24
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=48'>
         48
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=96'>
         96
       </a>
-
-
+      
+    
     )
-
+    
       <span class='grid-list-selector'>
   <a href='?display=grid'>
     <i class="fa fa-th"></i>
@@ -605,8 +702,32 @@
 </span>
 
 
-
+    
   </div>
 </div>
 
 
+
+    </div>
+    
+
+<div id='footer' class='container-fluid'>
+  
+    Memopol is free software
+    <a href="https://gitorious.org/memopol2-0">released</a>
+    under the terms of the
+    <a href="http://www.gnu.org/licenses/agpl.html">GNU aGPLV3+</a>
+  
+  <a href='https://projets.lqdn.fr/projects/mempol'>
+    Bug tracking system
+  </a>
+  <a href='https://projets.lqdn.fr/projects/mempol/issues/new'>
+    Report a bug
+  </a>
+  <br />
+  Provided by <a href="http://www.laquadrature.net/">La Quadrature du Net</a>
+
+</div>
+
+  </body>
+</html>
diff --git a/memopol/tests/RepresentativeListTest/test_page2_paginateby24_displaylist.html b/memopol/tests/response_fixtures/RepresentativeListTest.test_page2_paginateby24_displaylist/content
similarity index 74%
rename from memopol/tests/RepresentativeListTest/test_page2_paginateby24_displaylist.html
rename to memopol/tests/response_fixtures/RepresentativeListTest.test_page2_paginateby24_displaylist/content
index b495b308..6ee36005 100644
--- a/memopol/tests/RepresentativeListTest/test_page2_paginateby24_displaylist.html
+++ b/memopol/tests/response_fixtures/RepresentativeListTest.test_page2_paginateby24_displaylist/content
@@ -1,7 +1,80 @@
-    <div class="container-fluid main-container">
+<!DOCTYPE html>
+<html class="no-js" lang="en"> <!--<![endif]-->
+  <head>
+    <meta charset="utf-8" />
+    <link rel="icon" type="image/png" href="/static/collected/img/favicon.ico" />
+    <!-- Set the viewport width to device width for mobile -->
+    <meta name="viewport" content="width=device-width" />
+    <title>
+      Home
+      - The Political Memory of </title>
+    
+    
+    <link rel="stylesheet" href="/static/collected/libs/bootstrap/dist/css/bootstrap.min.css" type="text/css" /><link rel="stylesheet" href="/static/collected/libs/fontawesome/css/font-awesome.min.css" type="text/css" /><link rel="stylesheet" href="/static/collected/libs/flag-icon-css/css/flag-icon.min.css" type="text/css" /><link rel="stylesheet" href="/static/collected/CACHE/css/base.53baf9815401.css" type="text/css" />
+    <script type="text/javascript" src="/static/collected/libs/jquery/dist/jquery.js"></script>
+<script type="text/javascript" src="/static/collected/libs/bootstrap/dist/js/bootstrap.js"></script>
+    
+  </head>
+  <body >
+    <!-- -load memopol_tags cache -->
+
+
+
+
+<div id='header' class='container-fluid'>
+  <a id='logo' href='/'>
+    <img src='/static/collected/images/logo.png' />
+  </a>
+  <h1>
+    <a id='header_banner' href='/'>
+      Political Memory
+    </a>
+  </h1>
+  <p class='organization'>
+    
+
+  </p>
+</div>
+<div id='nav' class='container-fluid'>
+  <ul class='nav'>
+    <li>
+      <a href='/legislature/representative/'>
+        Representatives
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/country/'>
+        Countries
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/group/'>
+        Parties
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/delegation/'>
+        Delegations
+      </a>
+    </li>
+    <li>
+      <a href='/legislature/groups/committee/'>
+        Committees
+      </a>
+    </li>
+    <li>
+      <a href='/votes/dossier/'>
+        Votes
 
+      </a>
+    </li>
+  </ul>
+</div>
 
+    <div class="container-fluid main-container">
+      
 
+  
 
     <form action='' method='get'>
       <label for='search'>
@@ -11,13 +84,13 @@
       <input type='submit' value='Go' />
 
     </form>
-
+  
 
   <div class='pagination-block'>
 
   <nav>
     <ul class='pagination pagination-sm'>
-
+      
         <li>
           <a aria-label='First' href='?&page=1'>
             <i aria-hidden="true" class="fa fa-chevron-circle-left"></i>
@@ -30,30 +103,30 @@
 
           </a>
         </li>
-
-
-
-
+      
+      
+        
+          
             <li>
               <a href='?&page=1'>
                 1
 
               </a>
             </li>
-
-
-
-
-
+          
+        
+      
+        
+          
             <li class='active'>
               <a href=''>
                 2
               </a>
             </li>
-
-
-
-
+          
+        
+      
+      
     </ul>
   </nav>
   <div class='count'>
@@ -62,35 +135,35 @@
     Number of displayed results :
     24
     (
-
+    
       <a href='?paginate_by=12'>
         12
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=24'>
         24
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=48'>
         48
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=96'>
         96
       </a>
-
-
+      
+    
     )
-
+    
       <span class='grid-list-selector'>
   <a href='?display=grid'>
     <i class="fa fa-th"></i>
@@ -102,12 +175,12 @@
 </span>
 
 
-
+    
   </div>
 </div>
 
 
-
+  
 
     <table class='table'>
       <tr>
@@ -128,7 +201,7 @@
 
         </th>
       </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/eva-joly/'>
@@ -143,8 +216,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/France/'>
               France [FR]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Greens/European%20Free%20Alliance/'>
@@ -156,7 +231,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/jarosaw-kalinowski/'>
@@ -171,8 +246,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Poland/'>
               Poland [PL]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20European%20People&#39;s%20Party%20(Christian%20Democrats)/'>
@@ -184,7 +261,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/andrey-kovatchev/'>
@@ -199,8 +276,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Bulgaria/'>
               Bulgaria [BG]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20European%20People&#39;s%20Party%20(Christian%20Democrats)/'>
@@ -212,7 +291,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/olle-ludvigsson/'>
@@ -227,8 +306,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Sweden/'>
               Sweden [SE]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Progressive%20Alliance%20of%20Socialists%20and%20Democrats%20in%20the%20European%20Parliament/'>
@@ -240,7 +321,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/sirpa-pietikainen/'>
@@ -255,8 +336,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Finland/'>
               Finland [FI]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20European%20People&#39;s%20Party%20(Christian%20Democrats)/'>
@@ -268,7 +351,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/frederique-ries/'>
@@ -283,8 +366,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Belgium/'>
               Belgium [BE]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Alliance%20of%20Liberals%20and%20Democrats%20for%20Europe/'>
@@ -296,7 +381,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/birgit-sippel/'>
@@ -311,8 +396,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Germany/'>
               Germany [DE]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Progressive%20Alliance%20of%20Socialists%20and%20Democrats%20in%20the%20European%20Parliament/'>
@@ -324,7 +411,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/charles-tannock/'>
@@ -339,8 +426,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/United%20Kingdom/'>
               United Kingdom [GB]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/European%20Conservatives%20and%20Reformists%20Group/'>
@@ -352,7 +441,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/ramon-tremosa-i-balcells/'>
@@ -367,8 +456,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Spain/'>
               Spain [ES]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Alliance%20of%20Liberals%20and%20Democrats%20for%20Europe/'>
@@ -380,7 +471,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/vladimir-urutchev/'>
@@ -395,8 +486,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Bulgaria/'>
               Bulgaria [BG]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20European%20People&#39;s%20Party%20(Christian%20Democrats)/'>
@@ -408,7 +501,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/ivo-vajgl/'>
@@ -423,8 +516,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Slovenia/'>
               Slovenia [SI]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Alliance%20of%20Liberals%20and%20Democrats%20for%20Europe/'>
@@ -436,7 +531,7 @@
 
           </td>
         </tr>
-
+      
         <tr>
           <td>
             <a href='/legislature/representative/cecilia-wikstrom/'>
@@ -451,8 +546,10 @@
             </a>
           </td>
           <td>
+            <a href='/legislature/representative/country/Sweden/'>
               Sweden [SE]
 
+            </a>
           </td>
           <td>
             <a href='/legislature/representative/group/Group%20of%20the%20Alliance%20of%20Liberals%20and%20Democrats%20for%20Europe/'>
@@ -464,15 +561,15 @@
 
           </td>
         </tr>
-
+      
     </table>
-
+  
 
   <div class='pagination-block'>
 
   <nav>
     <ul class='pagination pagination-sm'>
-
+      
         <li>
           <a aria-label='First' href='?&page=1'>
             <i aria-hidden="true" class="fa fa-chevron-circle-left"></i>
@@ -485,30 +582,30 @@
 
           </a>
         </li>
-
-
-
-
+      
+      
+        
+          
             <li>
               <a href='?&page=1'>
                 1
 
               </a>
             </li>
-
-
-
-
-
+          
+        
+      
+        
+          
             <li class='active'>
               <a href=''>
                 2
               </a>
             </li>
-
-
-
-
+          
+        
+      
+      
     </ul>
   </nav>
   <div class='count'>
@@ -517,35 +614,35 @@
     Number of displayed results :
     24
     (
-
+    
       <a href='?paginate_by=12'>
         12
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=24'>
         24
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=48'>
         48
       </a>
-
+      
         /
-
-
+      
+    
       <a href='?paginate_by=96'>
         96
       </a>
-
-
+      
+    
     )
-
+    
       <span class='grid-list-selector'>
   <a href='?display=grid'>
     <i class="fa fa-th"></i>
@@ -557,6 +654,32 @@
 </span>
 
 
-
+    
   </div>
 </div>
+
+
+
+    </div>
+    
+
+<div id='footer' class='container-fluid'>
+  
+    Memopol is free software
+    <a href="https://gitorious.org/memopol2-0">released</a>
+    under the terms of the
+    <a href="http://www.gnu.org/licenses/agpl.html">GNU aGPLV3+</a>
+  
+  <a href='https://projets.lqdn.fr/projects/mempol'>
+    Bug tracking system
+  </a>
+  <a href='https://projets.lqdn.fr/projects/mempol/issues/new'>
+    Report a bug
+  </a>
+  <br />
+  Provided by <a href="http://www.laquadrature.net/">La Quadrature du Net</a>
+
+</div>
+
+  </body>
+</html>
diff --git a/memopol/tests/test_representatives_list.py b/memopol/tests/test_representatives_list.py
index 20938611..f4f3cbb9 100644
--- a/memopol/tests/test_representatives_list.py
+++ b/memopol/tests/test_representatives_list.py
@@ -1,6 +1,8 @@
 # -*- coding: utf8 -*-
 from django.test import TestCase
 
+from responsediff.response import Response
+
 from .base import UrlGetTestMixin
 
 
@@ -23,7 +25,8 @@ class RepresentativeListTest(UrlGetTestMixin, TestCase):
             """
             self.response = self.client.get(url)
 
-        self.assertExpectedHtmlInResult()
+        expected = Response.for_test(self)
+        expected.assertNoDiff(self.response)
 
     def test_page1_paginateby12_displaylist(self):
         self.functional_test(1, 12, 'list')
diff --git a/setup.py b/setup.py
index bcd06ab4..3ef3b72f 100644
--- a/setup.py
+++ b/setup.py
@@ -15,7 +15,7 @@ setup(name='political-memory',
         'django-compressor>=1.6,<1.7',
         'django-datetime-widget>=0.9,<1.0',
         'django-filter>=0.11,<0.12',
-        'django-representatives>=0.0.6',
+        'django-representatives>=0.0.9',
         'django-representatives-votes>=0.0.7',
         'django-taggit>=0.17,<0.18',
         'django>=1.8,<1.9',
@@ -28,6 +28,7 @@ setup(name='political-memory',
     ],
     extras_require={
         'testing': [
+            'django-responsediff',
             'flake8',
             'pep8',
             'pytest',
diff --git a/templates/representatives/_representative_block.haml b/templates/representatives/_representative_block.haml
index 34f68f26..ecdc69bc 100644
--- a/templates/representatives/_representative_block.haml
+++ b/templates/representatives/_representative_block.haml
@@ -21,7 +21,8 @@
         %tr
           %th Country
           %td<
-            = representative.country|country_flag
+            %a{:href => "{{ representative.country.get_absolute_url }}"}
+              = representative.country|country_flag
         %tr
           %th Party
           %td<
diff --git a/templates/representatives/representative_grid.haml b/templates/representatives/representative_grid.haml
index e01ded07..d8c1dddb 100644
--- a/templates/representatives/representative_grid.haml
+++ b/templates/representatives/representative_grid.haml
@@ -16,7 +16,7 @@
             %a{'href': "{{ representative.get_absolute_url }}"}
               = representative.full_name
           %li.country
-            %a{'href': "{% url 'representatives:representative-list' group_kind='country' group=representative.country.code %}"}
+            %a{'href': "{{ representative.country.get_absolute_url }}"}
               = representative.country|country_flag
           %li.mandate
             %a{'href': "{{ representative.main_mandate.group.get_absolute_url }}"}
diff --git a/templates/representatives/representative_list.haml b/templates/representatives/representative_list.haml
index 7d73d499..4288114d 100644
--- a/templates/representatives/representative_list.haml
+++ b/templates/representatives/representative_list.haml
@@ -42,6 +42,7 @@
               = representative.full_name
 
           %td
+            %a{'href': "{{ representative.country.get_absolute_url }}"}
               = representative.country
 
           %td
-- 
GitLab