repo.or.cz
/
blog.pm-common-perl-mods.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Dont' commit when nothing was changed.
[blog.pm-common-perl-mods.git]
/
Rose-DB-Object-I18N
/
t
/
not-translated-i18n.t
blob
1b7b6e73ef94bc548041ab9f71c4f5b6d46baba8
1
#! /usr/bin/perl
2
3
use
strict
;
4
use
warnings
;
5
6
use
Test
::
More
'tests'
=>
1
;
7
8
use
lib
't/lib'
;
9
10
use
NewDB
;
11
use
User
;
12
use
User
::
Manager
;
13
14
my
$db
=
NewDB
->
new
();
15
16
$db
->
init
();
17
18
my
$u
=
User
->
new
(
19
name
=>
'asdf2aa1'
,
20
orig_lang
=>
'ru'
,
21
signature
=>
'hello'
22
);
23
$u
->
save
();
24
25
my
@not_translated
=
$u
->
not_translated_i18n
;
26
27
is_deeply
( [
map
{
$_
->
lang
}
@not_translated
], [
'en'
,
'ua'
] );
28
29
$u
->
delete
(
cascade
=>
1
);
30
31
1
;