• Publicidad

FAILED 9: - template text 3 did not match expected

¿Apenas comienzas con Perl? En este foro podrás encontrar y hacer preguntas básicas de Perl con respuestas aptas a tu nivel.

FAILED 9: - template text 3 did not match expected

Notapor thelearner » 2006-09-26 07:28 @353

Buenas a todos,
resulta que estoy intentando instalar el módulo Template:

/usr/bin/perl -MCPAN -e 'install "Template"'

y me da el siguiente error:

Código: Seleccionar todo
...
t/dumper..............ok
t/error...............ok
t/evalperl............ok
t/exception...........ok
t/factory.............ok
t/file................ok
t/fileline............ok 5/11FAILED 9:  - template text 3 did not match expected
t/fileline............FAILED test 9
        Failed 1/11 tests, 90.91% okay
t/filter..............ok
t/foreach.............ok
t/format..............ok
t/html................ok
...

Failed Test  Stat Wstat Total Fail  Failed  List of Failed
-------------------------------------------------------------------------------
t/fileline.t               11    1   9.09%  9
3 tests skipped.
Failed 1/81 test scripts, 98.77% okay. 1/2637 subtests failed, 99.96% okay.
make: *** [test_dynamic] Error 255
  /usr/bin/make test -- NOT OK
Running make install
  make test had returned bad status, won't install without force


he estado buscando pero no he encontrado nada concluyente.

La máquina sobre la que lo intento instalar tiene las siguientes versiones:

- Fedora Core 4 (Linux servertest 2.6.14-1.1637_FC4)
- Perl (v5.8.6 built for i386-linux-thread-multi)


A ver si alguien puede darme alguna pista.

Gracias de antemano.
thelearner
Perlero nuevo
Perlero nuevo
 
Mensajes: 4
Registrado: 2006-09-26 07:04 @336

Publicidad

Notapor kidd » 2006-09-26 09:35 @441

Hola:

Intenta instalarlo manualmente. Baja la nueva versión del Template, ahora está en la 2.15:
http://search.cpan.org/~abw/Template-Toolkit-2.15/

Después en tu sistema sigue los siguientes pasos:

1. Descomprime y Desempaca
Sintáxis: [ Descargar ] [ Ocultar ]
Using bash Syntax Highlighting
gzip -dc Template-Toolkit-2.15.tar.gz | tar -xof -
Coloreado en 0.003 segundos, usando GeSHi 1.0.8.4


2. Construye
Entra al directorio que se acaba de crear:
Sintáxis: [ Descargar ] [ Ocultar ]
Using bash Syntax Highlighting
cd Template-Toolkit-2.15.tar.gz/
Coloreado en 0.001 segundos, usando GeSHi 1.0.8.4


Después corre los siguiente comandos:
Sintáxis: [ Descargar ] [ Ocultar ]
Using bash Syntax Highlighting
perl Makefile.PL
make
make test
Coloreado en 0.001 segundos, usando GeSHi 1.0.8.4


3. Instala
Sintáxis: [ Descargar ] [ Ocultar ]
Using bash Syntax Highlighting
make install
Coloreado en 0.001 segundos, usando GeSHi 1.0.8.4



Listo, ya debes de poder instalar tu módulo de esa manera.


Saludos
Uriel Lizama Perl programmer fundador de Perl en Español
Perl Programming Language
Avatar de Usuario
kidd
Creador de Perl en Español
Creador de Perl en Español
 
Mensajes: 1166
Registrado: 2003-10-15 16:52 @744
Ubicación: México

Notapor thelearner » 2006-09-28 01:44 @114

Gracias kidd por tu rápida respuesta. Hasta hoy no lo he podido probar.
Todo va bien hasta que ejecuto el "make test" y entonces me aparece de nuevo el error:

Código: Seleccionar todo
...
t/evalperl............ok
t/exception...........ok
t/factory.............ok
t/file................ok
t/fileline............ok 5/11FAILED 9:  - template text 3 did not match expected
t/fileline............FAILED test 9
        Failed 1/11 tests, 90.91% okay
t/filter..............ok
t/foreach.............ok
t/format..............ok

...

t/wrap................ok
t/wrapper.............ok
Failed Test  Stat Wstat Total Fail  Failed  List of Failed
-------------------------------------------------------------------------------
t/fileline.t               11    1   9.09%  9
3 tests skipped.
Failed 1/81 test scripts, 98.77% okay. 1/2637 subtests failed, 99.96% okay.
make: *** [test_dynamic] Error 255



¿ Alguna sugerencia ?

Gracias de nuevo.
thelearner
Perlero nuevo
Perlero nuevo
 
Mensajes: 4
Registrado: 2006-09-26 07:04 @336

Ampliando información

Notapor thelearner » 2006-09-28 02:03 @127

Más datos: después de ejecutar el make test pero activando el flag para ver los resultados en detalle de los tests
Sintáxis: [ Descargar ] [ Ocultar ]
Using bash Syntax Highlighting
 make test TEST_VERBOSE=1
Coloreado en 0.001 segundos, usando GeSHi 1.0.8.4


Se obtiene el siguiente mensaje:

Código: Seleccionar todo
t/fileline............1..11
ok 1 - running test_expect()
ok 2 - template processor is engaged
ok 3 - input read and split into 4 tests
ok 4 - template text 1 processed OK: [% place = 'World' -%]\nHello [% ...
ok 5 - template text 1 matched expected
ok 6 - template text 2 processed OK: [% INCLUDE warning -%]\nfile: [% ...
ok 7 - template text 2 matched expected
ok 8 - template text 3 processed OK: [% INCLUDE warning -%]\nfile: [% ...
MATCH FAILED
 input: [[% INCLUDE warning -%]\nfile: [% file.chunk(-16).last %]\nline: [% line %]\nwarn: [% warn
expect: [Hello\nWorld\nfile: (eval 10)\nline: 10\nwarn: Argument "" isn't numeric in addition (+)]
output: [Hello\nWorld\nfile: (eval 9)\nline: 10\nwarn: Argument "" isn't numeric in addition (+)]
not ok 9 - template text 3 did not match expected
ok 10 - template text 4 processed OK: [% TRY; \n     INCLUDE chomp; \n  ...
ok 11 - template text 4 matched expected
FAILED test 9
        Failed 1/11 tests, 90.91% okay
thelearner
Perlero nuevo
Perlero nuevo
 
Mensajes: 4
Registrado: 2006-09-26 07:04 @336

SOLUCIÓN

Notapor thelearner » 2006-09-28 02:14 @135

¡¡ Ya lo tengo !!
Se trata de un problema con la versión 2.15 que se resuelve en la 2.15b.

Reportado en: http://www.template-toolkit.org/pipermail/templates/2006-July/008807.html

La versión 2.15b se puede bajar de http://www.mail-archive.com/[email protected]/msg07951.html

Gracias y un saludo.
thelearner
Perlero nuevo
Perlero nuevo
 
Mensajes: 4
Registrado: 2006-09-26 07:04 @336


Volver a Básico

¿Quién está conectado?

Usuarios navegando por este Foro: No hay usuarios registrados visitando el Foro y 26 invitados

cron