snappymail/tests/Common/NpmTest.php

25 lines
452 B
PHP
Raw Normal View History

2016-05-25 03:27:11 +08:00
<?php
namespace CommonTests;
class NpmTest extends \PHPUnit_Framework_TestCase
{
public function testJsValidate()
{
$out = array();
2016-07-02 18:50:03 +08:00
// exec('gulp js:validate', $out);
// $this->assertTrue(0 < \count($out));
exec('eslint -c .eslintrc.js dev/*', $out);
$this->assertTrue(\is_array($out));
2016-07-01 07:16:35 +08:00
$noProblem = false === \strpos(\implode('|', $out), 'problem');
if (!$noProblem)
{
var_dump($out);
}
$this->assertTrue($noProblem);
2016-05-25 03:27:11 +08:00
}
}