Bit of cleanup, renamespaced, testing/code coverage
This commit is contained in:
parent
0af0ed0748
commit
80fa6ab88e
6 changed files with 41 additions and 14 deletions
1
.coveralls.yml
Normal file
1
.coveralls.yml
Normal file
|
@ -0,0 +1 @@
|
|||
service_name: travis-ci
|
26
.travis.yml
Normal file
26
.travis.yml
Normal file
|
@ -0,0 +1,26 @@
|
|||
language: php
|
||||
|
||||
php:
|
||||
- 5.3
|
||||
- 5.4
|
||||
- 5.5
|
||||
- 5.6
|
||||
- 7.0
|
||||
- hhvm
|
||||
|
||||
matrix:
|
||||
allow_failures:
|
||||
- php: hhvm
|
||||
|
||||
install:
|
||||
- composer install
|
||||
|
||||
before_script:
|
||||
- mkdir -p build/logs
|
||||
- cd tests
|
||||
|
||||
script:
|
||||
- phpunit --colors --coverage-clover /home/travis/build/joshtronic/php-sort/build/logs/clover.xml .
|
||||
|
||||
after_success:
|
||||
- php ../vendor/bin/coveralls --config ../.coveralls.yml -v
|
2
LICENSE
2
LICENSE
|
@ -1,6 +1,6 @@
|
|||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2014 Josh Sherman
|
||||
Copyright (c) 2014, 2015, 2016, 2017 Josh Sherman
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
|
|
|
@ -7,14 +7,12 @@
|
|||
"php": ">=5.3"
|
||||
}
|
||||
},
|
||||
"require-dev": {
|
||||
"satooshi/php-coveralls": "~1.0"
|
||||
}
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Pickles\\": "src"
|
||||
"joshtronic\\": "src"
|
||||
}
|
||||
},
|
||||
"autoload-dev": {
|
||||
"psr-4": {
|
||||
"Pickles\\Tests\\": "tests"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -6,13 +6,13 @@
|
|||
* Licensed under The MIT License
|
||||
* Redistribution of these files must retain the above copyright notice.
|
||||
*
|
||||
* @copyright Copyright 2007-2014, Josh Sherman
|
||||
* @author Josh Sherman <hello@joshtronic.com>
|
||||
* @copyright Copyright 2007-2017, Josh Sherman
|
||||
* @license http://www.opensource.org/licenses/mit-license.html
|
||||
* @link https://github.com/joshtronic/pickles
|
||||
* @package Pickles
|
||||
* @link https://github.com/joshtronic/php-sort
|
||||
*/
|
||||
|
||||
namespace Pickles;
|
||||
namespace joshtronic;
|
||||
|
||||
/**
|
||||
* Sort Class
|
||||
|
@ -66,3 +66,4 @@ class Sort
|
|||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
<?php
|
||||
|
||||
namespace Pickles\Tests;
|
||||
require_once '../src/Sort.php';
|
||||
|
||||
use Pickles\Sort;
|
||||
use joshtronic\Sort;
|
||||
|
||||
class SortTest extends \PHPUnit_Framework_TestCase
|
||||
class SortTest extends PHPUnit_Framework_TestCase
|
||||
{
|
||||
public function testByNameASC()
|
||||
{
|
||||
|
@ -62,3 +62,4 @@ class SortTest extends \PHPUnit_Framework_TestCase
|
|||
$this->assertEquals($sorted, $shuffled);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue