public void TestDevuelvaFormatoCorrectoDeFrasesClaves() { PlataformaStub plataforma = new PlataformaStub("me gusta el futbol"); AdapterAzure adapter = new AdapterAzure(); List <string> frases = new List <string> (); List <string> frasesAzure = adapter.GetFrasesClave(plataforma.RecibirMensaje()); frases.Add("futbol"); Assert.AreEqual(frases, frasesAzure); }
public void TestSiRecibeNumeroDevuelveTipoNumero() { ArchivoInteraccionesStub archivo = new ArchivoInteraccionesStub(); PlataformaStub plataforma = new PlataformaStub("500"); ProcesadorStub procesador = new ProcesadorStub(); procesador.SetPlataforma(plataforma); TaggerMensajes tagger = new TaggerMensajes(archivo, procesador); Mensaje mensaje = tagger.EtiquetarMensaje(); Assert.AreEqual(mensaje.Tipo(), TipoMensaje.Numero); }
public void TestSiRecibeDesconocidoDevuelveTipoOtros() { ArchivoInteraccionesStub archivo = new ArchivoInteraccionesStub(); PlataformaStub plataforma = new PlataformaStub("ajklsdfhnkajbsacbkzdbajkbf"); ProcesadorStub procesador = new ProcesadorStub(); procesador.SetPlataforma(plataforma); TaggerMensajes tagger = new TaggerMensajes(archivo, procesador); Mensaje mensaje = tagger.EtiquetarMensaje(); Assert.AreEqual(mensaje.Tipo(), TipoMensaje.Otros); }