Instalación de PHPUnit a través de PEAR
Tengo problemas instalando PHPUnit 3.4.6 vía PEAR 1.9.0. Después de descubrir el canal pear.phpunit.de e intenta usar uno de los siguientes comandos:
Pear instalar phpunit / PHPUnit
Pear install all alldeps phpunit / PHPUnit
Pear install on onlyreqdeps phpunit / PHPUnit
Falla, dándome el siguiente error:
No hay versiones disponibles para el paquete "pear.phpunit.de/PHPUnit"
Instalar failed
Encontré varios hilos de personas con el mismo problema, pero actualizar PEAR a la versión más reciente generalmente funcionó para ellos. También parece que no hay tutoriales para instalar PHPUnit para Windows.
EDITAR:
También he intentado cambiar prefered_state a beta; no ayudó.
También he intentado obtener una lista de todos los paquetes disponibles:
Pear remote-list-c phpunit
Me da otro error:
No se puede descargar URL no http "/c/categories.xml"
13 answers
Tuve el mismo problema ayer, y lo solucioné actualizando los canales
pear clear-cache
pear update-channels
Antes de intentar instalar PHPUnit.
Espero que esto ayude.
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2014-03-26 19:27:46
Tuve el mismo problema, intente:
pear clear-cache
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2011-07-14 18:35:46
Simplemente me instala cuando escribo:
pear channel-discover pear.phpunit.de
pear install --onlyreqdeps phpunit/PHPUnit
Tal vez haya un problema con las versiones, puede establecer el preferred_state de los paquetes pear a diferente de stable :
pear config-set preferred_state beta
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2012-09-16 12:11:06
Por favor, siga estos pasos:
-
1.
pear config-set auto_discover 1
-
2.
pear install pear.phpunit.de/PHPUnit
- > aquí tengo: la instalación falló.
-
3. Try:
pear clear-cache
- >ejecutado con éxito
-
4.
pear update-channels
- >ejecutado con éxito
-
5.
pear install pear.phpunit.de/PHPUnit
- >ejecutado con éxito.
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2012-12-25 08:51:41
Yo tenía el mismo problema. esto funcionó para mí:
sudo pear clear-cache
sudo pear channel-discover pear.phpunit.de
sudo pear channel-discover pear.symfony-project.com
pear install --alldeps phpunit/PHPUnit
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2011-11-01 08:46:57
¿Cuál es la salida completa del mensaje de error? Falló para mí hasta que instalé usando la opción --alldeps
y corrí pear channel-discover pear.symfony-project.com
sudo pear channel-discover pear.phpunit.de
sudo pear channel-discover pear.symfony-project.com
sudo pear install --alldeps phpunit/PHPUnit
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2010-01-05 17:13:33
Desde 2014-12-31 PEAR Installer ya no era el único método de instalación para PHPUnit Ver aquí: https://github.com/sebastianbergmann/phpunit/wiki/End-of-Life-for-PEAR-Installation-Method
Lo intenté
pear update-channels
Como sugirió Davide anteriormente, pero eso me dio el error
Channel pear.php.net does not support xml-rpc method channel.listAll
Por alguna razón, funcionó cuando corrí
pear channel-update pear.phpunit.de
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2010-11-16 15:51:15
También necesitas descubrir el canal ezcomponents usando pear channel-discover components.ez.no
En total:
sudo pear channel-discover pear.phpunit.de
sudo pear channel-discover pear.symfony-project.com
sudo pear channel-discover components.ez.no
sudo pear install --alldeps phpunit/PHPUnit
Puede tener una comprobación rápida de cordura para ejecutar phpunit desde la CLI y ver si el comando es reconocido.
UPDATE
Parece que han movido symfony, acabo de hacer una nueva instalación hoy, aquí está el nuevo canal
sudo pear channel-discover pear.symfony.com
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2013-05-16 05:11:45
Tengo el mismo problema con la instalación de phpunit. Intente usar Synaptic package manager para la instalación de PHPUnit.
sudo pear install pear # upgrade pear first
#install php unit with synaptic manager
phpunit --version # get version of phpunit
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2011-05-06 12:24:38
Yo había luchado durante años con conseguir ZEND etc para trabajar en XAMPP en Windows Vista. Como referencia, así es como lo resolví: -
No pude actualizar PEAR, entonces me di cuenta de que su configuración de ruta predeterminada era incorrecta, corrijo esta guía...
Http://david-franklin.net/programming/installing-pear-phpunit-on-windows /
Luego logré instalar PHPUNIT con el comando pear clear_cache
gracias a este hilo luego ejecuté "pear install phpunit/PHPUnit".
Espero lo que escrito anteriormente servirá como un código rápido para aquellos en una situación similar (me tomó 2 días enteros para conseguir que funcione!!!)
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2012-11-12 21:00:59
Tuve un problema con no tener una dependencia YAML requerida, así que recibí una advertencia cada vez.
Intente
pear channel-discover pear.symfony.com
pear install pear.symfony.com/Yaml
A continuación, ejecute la descarga de nuevo
pear install --alldeps pear.phpunit.de/PHPUnit
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2012-11-17 14:12:26
En primer lugar, todo xampp debe instalarse en C:\xampp
Abra un símbolo del sistema y vaya a C:\xampp\php
Escriba los siguientes comandos en el cmd
pear update-channels
" (actualizaciones de definiciones de canal)
pear upgrade
(actualiza todos los paquetes existentes y pear)
pear channel-discover components.ez.no
(esto es necesario para PHPUnit)
pear channel-discover pear.symfony-project.com
(también es necesario por PHPUnit)
pear channel-discover pear.phpunit.de
(Esto ES phpunit)
pear install --alldeps phpunit/PHPUnit
(instala PHPUnit y todas las dependencias)
Warning: date(): Invalid date.timezone value 'Europe/Kyiv', we selected the timezone 'UTC' for now. in /var/www/agent_stack/data/www/ajaxhispano.com/template/agent.layouts/content.php on line 61
2013-12-24 17:03:34