on master help sign in
change rest of test_startpage.py
83a06d2Michael Pfitzner
tests/unit/engines/test_startpage.py+8−8
@@ -67,14 +67,14 @@ class TestStartpageEngine(SearxTestCase):
67 self.assertEqual(results[0]['content'], 'This should be the content.')
67 self.assertEqual(results[0]['content'], 'This should be the content.')
68
68
69 html = """
69 html = """
70− <div class='result' style=' *width : auto; *margin-right : 10%;'>
70+ <li class="search-result search-item">
71 <h3>
71 <h3>
72 <a href='http://www.google.com/aclk?sa=l&ai=C' id='title_2' name='title_2' >
72 <a href='http://www.google.com/aclk?sa=l&ai=C' id='title_2' name='title_2' >
73 This should be the title
73 This should be the title
74 </a>
74 </a>
75 <span id='title_stars_2' name='title_stars_2'> </span>
75 <span id='title_stars_2' name='title_stars_2'> </span>
76 </h3>
76 </h3>
77− <p class='desc clk'>
77+ <p class="search-item__body">
78 This should be the content.
78 This should be the content.
79 </p>
79 </p>
80 <p>
80 <p>
@@ -92,20 +92,20 @@ class TestStartpageEngine(SearxTestCase):
92 Mis en surbrillance
92 Mis en surbrillance
93 </A>
93 </A>
94 </p>
94 </p>
95− </div>
95+ </li>
96− <div class='result' style=' *width : auto; *margin-right : 10%;'>
96+ <li class="search-result search-item">
97 <h3>
97 <h3>
98 <span id='title_stars_2' name='title_stars_2'> </span>
98 <span id='title_stars_2' name='title_stars_2'> </span>
99 </h3>
99 </h3>
100− <p class='desc clk'>
100+ <p class="search-item__body">
101 This should be the content.
101 This should be the content.
102 </p>
102 </p>
103 <p>
103 <p>
104 <span class='url'>www.speed<b>test</b>.net/fr/
104 <span class='url'>www.speed<b>test</b>.net/fr/
105 </span>
105 </span>
106 </p>
106 </p>
107− </div>
107+ </li>
108− <div class='result' style=' *width : auto; *margin-right : 10%;'>
108+ <li class="search-result search-item">
109 <h3>
109 <h3>
110 <a href='http://this.should.be.the.link/' id='title_2' name='title_2' >
110 <a href='http://this.should.be.the.link/' id='title_2' name='title_2' >
111 This should be the title
111 This should be the title
@@ -127,7 +127,7 @@ class TestStartpageEngine(SearxTestCase):
127 Mis en surbrillance
127 Mis en surbrillance
128 </A>
128 </A>
129 </p>
129 </p>
130− </div>
130+ </li>
131 """
131 """
132 response = mock.Mock(text=html.encode('utf-8'))
132 response = mock.Mock(text=html.encode('utf-8'))
133 results = startpage.response(response)
133 results = startpage.response(response)