예제 #1
0
 def setup_class(cls):
     a = Widget(2)
     cls.clase = Logaritmo_natural(valor=None, hijos=[a])
예제 #2
0
 def test_agregar_hijo(self):
     c = Widget(pi / 2)
     assert self.clase.agregar_hijo(c.tipo.valor) is False
예제 #3
0
 def test_operacion(self):
     c = Widget(1)
     self.clase.hijos.append(c)
     self.clase.operacion()
     assert self.clase.valor == 2
예제 #4
0
 def setup_class(cls):
     a = Widget(2)
     b = Widget(0)
     cls.clase = Potencia(valor=None, hijos=[a, b])
예제 #5
0
 def setup_class(cls):
     a = Widget(2)
     cls.clase = Division(valor=None, hijos=[a])
예제 #6
0
 def test_agregar_hijo(self):
     b = Widget(0)
     assert self.clase.agregar_hijo(b.tipo.valor) is False
예제 #7
0
 def setup_class(cls):
     a = Widget(2)
     b = Widget(0)
     cls.multiplicacion = Multiplicacion(valor=None, hijos=[a, b])
예제 #8
0
 def test_agregar_hijo(self):
     c = Widget(pi / 2)
     assert self.multiplicacion.agregar_hijo(c.tipo.valor) is False
예제 #9
0
 def test_agregar_hijo(self):
     c = Widget(pi / 2)
     assert self.suma.agregar_hijo(c) is False
예제 #10
0
 def setup_class(cls):
     a = Widget(2)
     b = Widget(0)
     cls.resta = Resta(valor=None, hijos=[a, b])
예제 #11
0
 def setup_class(cls):
     a = Widget(2)
     b = Widget(0)
     c = Widget(3)
     d = Widget(-3)
     cls.clase = Minimo(valor=None, hijos=[a, b, c, d])
예제 #12
0
 def test_operacion(self):
     a = Widget(2)
     self.clase.hijos.append(a)
     self.clase.operacion()
     assert self.clase.valor == tan(2)
예제 #13
0
 def setup_class(cls):
     a = Widget(2)
     cls.clase = Coseno(valor=None, hijos=[a])
예제 #14
0
 def setup_class(cls):
     a = Widget(2)
     cls.clase = Valor_absoluto(valor=None, hijos=[a])
예제 #15
0
 def setup_class(cls):
     a = Widget(2)
     b = Widget(0)
     cls.suma = Suma(valor=None, hijos=[a, b])