mirror of
https://github.com/silverstripe/silverstripe-comments
synced 2024-10-22 11:05:49 +02:00
NEW Convert to vendor module, add table_name to test stubs and add PHP 7.2 to travis
This commit is contained in:
parent
8919f6da2a
commit
c6f8973342
1
.gitattributes
vendored
1
.gitattributes
vendored
@ -4,3 +4,4 @@
|
|||||||
/.gitignore export-ignore
|
/.gitignore export-ignore
|
||||||
/.travis.yml export-ignore
|
/.travis.yml export-ignore
|
||||||
/.scrutinizer.yml export-ignore
|
/.scrutinizer.yml export-ignore
|
||||||
|
/codecov.yml export-ignore
|
||||||
|
@ -9,6 +9,8 @@ matrix:
|
|||||||
env: DB=PGSQL PHPUNIT_TEST=1
|
env: DB=PGSQL PHPUNIT_TEST=1
|
||||||
- php: 7.1
|
- php: 7.1
|
||||||
env: DB=MYSQL PHPUNIT_COVERAGE_TEST=1
|
env: DB=MYSQL PHPUNIT_COVERAGE_TEST=1
|
||||||
|
- php: 7.2
|
||||||
|
env: DB=MYSQL PHPUNIT_TEST=1
|
||||||
|
|
||||||
before_script:
|
before_script:
|
||||||
- phpenv rehash
|
- phpenv rehash
|
||||||
@ -21,7 +23,7 @@ before_script:
|
|||||||
script:
|
script:
|
||||||
- if [[ $PHPUNIT_TEST ]]; then vendor/bin/phpunit; fi
|
- if [[ $PHPUNIT_TEST ]]; then vendor/bin/phpunit; fi
|
||||||
- if [[ $PHPUNIT_COVERAGE_TEST ]]; then phpdbg -qrr vendor/bin/phpunit --coverage-clover=coverage.xml; fi
|
- if [[ $PHPUNIT_COVERAGE_TEST ]]; then phpdbg -qrr vendor/bin/phpunit --coverage-clover=coverage.xml; fi
|
||||||
- if [[ $PHPCS_TEST ]]; then vendor/bin/phpcs --standard=vendor/silverstripe/framework/phpcs.xml.dist src/ tests/ ; fi
|
- if [[ $PHPCS_TEST ]]; then vendor/bin/phpcs src/ tests/ *.php; fi
|
||||||
|
|
||||||
after_success:
|
after_success:
|
||||||
- if [[ $PHPUNIT_COVERAGE_TEST ]]; then bash <(curl -s https://codecov.io/bash) -f coverage.xml; fi
|
- if [[ $PHPUNIT_COVERAGE_TEST ]]; then bash <(curl -s https://codecov.io/bash) -f coverage.xml; fi
|
||||||
|
@ -1,14 +1,14 @@
|
|||||||
{
|
{
|
||||||
"name": "silverstripe/comments",
|
"name": "silverstripe/comments",
|
||||||
"description": "This module provides commenting functionality for Pages and other DataObjects on your SilverStripe site.",
|
"description": "This module provides commenting functionality for Pages and other DataObjects on your SilverStripe site.",
|
||||||
"type": "silverstripe-module",
|
"type": "silverstripe-vendormodule",
|
||||||
"keywords": ["silverstripe", "comments"],
|
"keywords": ["silverstripe", "comments"],
|
||||||
"authors": [{
|
"authors": [{
|
||||||
"name": "Will Rossiter",
|
"name": "Will Rossiter",
|
||||||
"email": "will@fullscreen.io"
|
"email": "will@fullscreen.io"
|
||||||
}],
|
}],
|
||||||
"require": {
|
"require": {
|
||||||
"silverstripe/framework": "^4.0@dev",
|
"silverstripe/framework": "^4.0",
|
||||||
"colymba/gridfield-bulk-editing-tools": "^3.0"
|
"colymba/gridfield-bulk-editing-tools": "^3.0"
|
||||||
},
|
},
|
||||||
"suggest": {
|
"suggest": {
|
||||||
@ -22,7 +22,11 @@
|
|||||||
"extra": {
|
"extra": {
|
||||||
"branch-alias": {
|
"branch-alias": {
|
||||||
"dev-master": "3.x-dev"
|
"dev-master": "3.x-dev"
|
||||||
}
|
},
|
||||||
|
"expose": [
|
||||||
|
"css",
|
||||||
|
"javascript"
|
||||||
|
]
|
||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"lint": "vendor/bin/phpcs src/ tests/",
|
"lint": "vendor/bin/phpcs src/ tests/",
|
||||||
|
@ -2,7 +2,6 @@
|
|||||||
|
|
||||||
namespace SilverStripe\Comments\Tests\Stubs;
|
namespace SilverStripe\Comments\Tests\Stubs;
|
||||||
|
|
||||||
use SilverStripe\Comments\Tests\Stubs\CommentableItem;
|
|
||||||
use SilverStripe\Control\Controller;
|
use SilverStripe\Control\Controller;
|
||||||
use SilverStripe\Dev\TestOnly;
|
use SilverStripe\Dev\TestOnly;
|
||||||
|
|
||||||
|
@ -2,8 +2,6 @@
|
|||||||
|
|
||||||
namespace SilverStripe\Comments\Tests\Stubs;
|
namespace SilverStripe\Comments\Tests\Stubs;
|
||||||
|
|
||||||
use SilverStripe\Comments\Tests\Stubs\CommentableItem;
|
|
||||||
|
|
||||||
class CommentableItemDisabled extends CommentableItem
|
class CommentableItemDisabled extends CommentableItem
|
||||||
{
|
{
|
||||||
private static $defaults = array(
|
private static $defaults = array(
|
||||||
@ -11,4 +9,6 @@ class CommentableItemDisabled extends CommentableItem
|
|||||||
'ModerationRequired' => 'None',
|
'ModerationRequired' => 'None',
|
||||||
'CommentsRequireLogin' => false
|
'CommentsRequireLogin' => false
|
||||||
);
|
);
|
||||||
|
|
||||||
|
private static $table_name = 'CommentableItemDisabled';
|
||||||
}
|
}
|
||||||
|
@ -2,8 +2,6 @@
|
|||||||
|
|
||||||
namespace SilverStripe\Comments\Tests\Stubs;
|
namespace SilverStripe\Comments\Tests\Stubs;
|
||||||
|
|
||||||
use SilverStripe\Comments\Tests\Stubs\CommentableItem;
|
|
||||||
|
|
||||||
class CommentableItemEnabled extends CommentableItem
|
class CommentableItemEnabled extends CommentableItem
|
||||||
{
|
{
|
||||||
private static $defaults = array(
|
private static $defaults = array(
|
||||||
@ -11,4 +9,6 @@ class CommentableItemEnabled extends CommentableItem
|
|||||||
'ModerationRequired' => 'Required',
|
'ModerationRequired' => 'Required',
|
||||||
'CommentsRequireLogin' => true
|
'CommentsRequireLogin' => true
|
||||||
);
|
);
|
||||||
|
|
||||||
|
private static $table_name = 'CommentableItemEnabled';
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user