Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
TelegramBot
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kulya
TelegramBot
Commits
84977ea7
Unverified
Commit
84977ea7
authored
Apr 22, 2018
by
Avtandil Kikabidze
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Rename logger test
parent
e550a76c
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
LoggerTest.php
tests/unit/LoggerTest.php
+5
-5
No files found.
tests/unit/
TelegramLog
Test.php
→
tests/unit/
Logger
Test.php
View file @
84977ea7
...
@@ -12,7 +12,7 @@ namespace Longman\TelegramBot\Tests\Unit;
...
@@ -12,7 +12,7 @@ namespace Longman\TelegramBot\Tests\Unit;
use
Longman\TelegramBot\Logger
;
use
Longman\TelegramBot\Logger
;
use
Monolog\Handler\StreamHandler
;
use
Monolog\Handler\StreamHandler
;
use
Monolog\Logger
;
use
Monolog\Logger
as
MonologLogger
;
/**
/**
* @package TelegramTest
* @package TelegramTest
...
@@ -21,7 +21,7 @@ use Monolog\Logger;
...
@@ -21,7 +21,7 @@ use Monolog\Logger;
* @license http://opensource.org/licenses/mit-license.php The MIT License (MIT)
* @license http://opensource.org/licenses/mit-license.php The MIT License (MIT)
* @link https://github.com/php-telegram-bot/core
* @link https://github.com/php-telegram-bot/core
*/
*/
class
TelegramLog
Test
extends
TestCase
class
Logger
Test
extends
TestCase
{
{
/**
/**
* @var array Dummy logfile paths
* @var array Dummy logfile paths
...
@@ -121,9 +121,9 @@ class TelegramLogTest extends TestCase
...
@@ -121,9 +121,9 @@ class TelegramLogTest extends TestCase
$file
=
self
::
$logfiles
[
'external'
];
$file
=
self
::
$logfiles
[
'external'
];
$this
->
assertFileNotExists
(
$file
);
$this
->
assertFileNotExists
(
$file
);
$external_monolog
=
new
Logger
(
'bot_update_log'
);
$external_monolog
=
new
Monolog
Logger
(
'bot_update_log'
);
$external_monolog
->
pushHandler
(
new
StreamHandler
(
$file
,
Logger
::
ERROR
));
$external_monolog
->
pushHandler
(
new
StreamHandler
(
$file
,
Monolog
Logger
::
ERROR
));
$external_monolog
->
pushHandler
(
new
StreamHandler
(
$file
,
Logger
::
DEBUG
));
$external_monolog
->
pushHandler
(
new
StreamHandler
(
$file
,
Monolog
Logger
::
DEBUG
));
Logger
::
initialize
(
$external_monolog
);
Logger
::
initialize
(
$external_monolog
);
Logger
::
error
(
'my error'
);
Logger
::
error
(
'my error'
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment