Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F120836838
Getunread.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Authored By
Unknown
Size
1 KB
Referenced Files
None
Subscribers
None
Getunread.php
View Options
<?php
namespace
Tests\Browser\Mail
;
class
Getunread
extends
\Tests\Browser\TestCase
{
protected
static
$msgcount
=
0
;
public
static
function
setUpBeforeClass
()
{
\bootstrap
::
init_imap
();
\bootstrap
::
purge_mailbox
(
'INBOX'
);
// import email messages
foreach
(
glob
(
TESTS_DIR
.
'data/mail/list_??.eml'
)
as
$f
)
{
\bootstrap
::
import_message
(
$f
,
'INBOX'
);
self
::
$msgcount
++;
}
}
public
function
testGetunread
()
{
$this
->
browse
(
function
(
$browser
)
{
$browser
->
go
(
'mail'
);
$browser
->
waitFor
(
'#messagelist tbody tr'
);
// Messages list state
$browser
->
assertElementsCount
(
'#messagelist tbody tr.unread'
,
self
::
$msgcount
);
if
(!
$browser
->
isDesktop
())
{
$browser
->
click
(
'.back-sidebar-button'
);
}
// Folders list state
$browser
->
assertVisible
(
'.folderlist li.inbox.unread'
);
$this
->
assertEquals
(
strval
(
self
::
$msgcount
),
$browser
->
text
(
'.folderlist li.inbox span.unreadcount'
));
});
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Fri, Apr 24, 1:36 PM (6 h, 52 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
18839103
Default Alt Text
Getunread.php (1 KB)
Attached To
Mode
R113 roundcubemail
Attached
Detach File
Event Timeline