Skip to content

Commit

Permalink
Merge pull request #2 from bigperson/analysis-zO4djl
Browse files Browse the repository at this point in the history
Apply fixes from StyleCI
  • Loading branch information
bigperson authored Oct 23, 2018
2 parents f0fbfd1 + 48140fe commit dc6a06b
Show file tree
Hide file tree
Showing 6 changed files with 99 additions and 106 deletions.
53 changes: 26 additions & 27 deletions src/Events/AbstractEventInterface.php
Original file line number Diff line number Diff line change
@@ -1,27 +1,26 @@
<?php
/**
* This file is part of bigperson/exchange1c package.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
declare(strict_types=1);


namespace Bigperson\Exchange1C\Events;

/**
* Class AbstractEventInterface
*/
abstract class AbstractEventInterface implements \Bigperson\Exchange1C\Interfaces\EventInterface
{
public const NAME = self::class;

/**
* @return string
*/
public function getName(): string
{
return self::NAME;
}
}
<?php
/**
* This file is part of bigperson/exchange1c package.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
declare(strict_types=1);

namespace Bigperson\Exchange1C\Events;

/**
* Class AbstractEventInterface.
*/
abstract class AbstractEventInterface implements \Bigperson\Exchange1C\Interfaces\EventInterface
{
public const NAME = self::class;

/**
* @return string
*/
public function getName(): string
{
return self::NAME;
}
}
44 changes: 21 additions & 23 deletions src/Interfaces/EventDispatcherInterface.php
Original file line number Diff line number Diff line change
@@ -1,23 +1,21 @@
<?php
/**
* This file is part of bigperson/exchange1c package.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
declare(strict_types=1);


namespace Bigperson\Exchange1C\Interfaces;

/**
* Interface EventDispatcherInterface
* @package Bigperson\Exchange1C\Interfaces
*/
interface EventDispatcherInterface
{
/**
* @param EventInterface $event
*/
public function dispatch(EventInterface $event): void;
}
<?php
/**
* This file is part of bigperson/exchange1c package.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
declare(strict_types=1);

namespace Bigperson\Exchange1C\Interfaces;

/**
* Interface EventDispatcherInterface.
*/
interface EventDispatcherInterface
{
/**
* @param EventInterface $event
*/
public function dispatch(EventInterface $event): void;
}
44 changes: 21 additions & 23 deletions src/Interfaces/EventInterface.php
Original file line number Diff line number Diff line change
@@ -1,23 +1,21 @@
<?php
/**
* This file is part of bigperson/exchange1c package.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
declare(strict_types=1);


namespace Bigperson\Exchange1C\Interfaces;

/**
* Interface EventInterface
* @package Bigperson\Exchange1C\Interfaces
*/
interface EventInterface
{
/**
* @return string
*/
public function getName(): string;
}
<?php
/**
* This file is part of bigperson/exchange1c package.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
declare(strict_types=1);

namespace Bigperson\Exchange1C\Interfaces;

/**
* Interface EventInterface.
*/
interface EventInterface
{
/**
* @return string
*/
public function getName(): string;
}
52 changes: 25 additions & 27 deletions tests/Events/EventTest.php
Original file line number Diff line number Diff line change
@@ -1,27 +1,25 @@
<?php
/**
* This file is part of bigperson/exchange1c package.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
declare(strict_types=1);


namespace Tests\Events;

use Bigperson\Exchange1C\Events\BeforeOffersSync;
use Tests\TestCase;

/**
* Class EventTest
*/
class EventTest extends TestCase
{
public function testGetName()
{
$event = new BeforeOffersSync();
$this->assertTrue(is_string($event->getName()));

}
}
<?php
/**
* This file is part of bigperson/exchange1c package.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
declare(strict_types=1);

namespace Tests\Events;

use Bigperson\Exchange1C\Events\BeforeOffersSync;
use Tests\TestCase;

/**
* Class EventTest.
*/
class EventTest extends TestCase
{
public function testGetName()
{
$event = new BeforeOffersSync();
$this->assertTrue(is_string($event->getName()));
}
}
6 changes: 3 additions & 3 deletions tests/Services/CategoryServiceTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,12 @@

namespace Tests\Services;

use Tests\TestCase;
use Bigperson\Exchange1C\Config;
use Bigperson\Exchange1C\Interfaces\EventDispatcherInterface;
use Bigperson\Exchange1C\ModelBuilder;
use Symfony\Component\HttpFoundation\Request;
use Bigperson\Exchange1C\Services\CategoryService;
use Bigperson\Exchange1C\Interfaces\EventDispatcherInterface;
use Symfony\Component\HttpFoundation\Request;
use Tests\TestCase;

class CategoryServiceTest extends TestCase
{
Expand Down
6 changes: 3 additions & 3 deletions tests/Services/OfferServiceTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,12 @@

namespace Tests\Services;

use Tests\TestCase;
use Bigperson\Exchange1C\Config;
use Bigperson\Exchange1C\Interfaces\EventDispatcherInterface;
use Bigperson\Exchange1C\ModelBuilder;
use Symfony\Component\HttpFoundation\Request;
use Bigperson\Exchange1C\Services\OfferService;
use Bigperson\Exchange1C\Interfaces\EventDispatcherInterface;
use Symfony\Component\HttpFoundation\Request;
use Tests\TestCase;

class OfferServiceTest extends TestCase
{
Expand Down

0 comments on commit dc6a06b

Please sign in to comment.