Example #1
0
 def test_clear(self):
     foo = Foo('ciclout')
     Foo.ajouter(foo)
     Foo.clear()
     self.assertEqual(Foo.get_liste(), [])
Example #2
0
 def test_on_peut_ajouter_des_foos(self):
     foo = Foo('ciblout')
     Foo.ajouter(foo)
     self.assertIn(foo, foo.get_liste())
Example #3
0
 def test_on_peut_avoir_plein_de_foo(self):
     liste_foo = Foo.get_liste()
     for foo in liste_foo:
         self.assertIsInstance(foo.name, str)
         self.assertIsInstance(foo.score, float)
         self.assertIsInstance(foo.__html__(), str)
Example #4
0
def index():
    foos = Foo.get_two_foos()
    return render_template('index.html', foos=foos, list_foos=Foo.get_liste())
Example #5
0
def index():
    foos = Foo.get_two_foos()
    return render_template('index.html', foos=foos, list_foos=Foo.get_liste())
Example #6
0
 def test_clear(self):
     foo = Foo('ciclout')
     Foo.ajouter(foo)
     Foo.clear()
     self.assertEqual(Foo.get_liste(), [])
Example #7
0
 def test_on_peut_avoir_plein_de_foo(self):
     liste_foo = Foo.get_liste()
     for foo in liste_foo:
         self.assertIsInstance(foo.name, str)
         self.assertIsInstance(foo.score, float)
         self.assertIsInstance(foo.__html__(), str)
Example #8
0
 def test_on_peut_ajouter_des_foos(self):
     foo = Foo('ciblout')
     Foo.ajouter(foo)
     self.assertIn(foo, foo.get_liste())