Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
lettuce
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
edx
lettuce
Commits
7782b42f
Commit
7782b42f
authored
May 08, 2010
by
Gabriel Falcão
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
organizing language-specific tests
parent
0dbd9957
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
31 additions
and
14 deletions
+31
-14
lettuce/languages.py
+1
-1
tests/unit/test_language.py
+0
-13
tests/unit/test_language_ptbr.py
+30
-0
No files found.
lettuce/languages.py
View file @
7782b42f
...
@@ -24,7 +24,7 @@ LANGUAGES = {
...
@@ -24,7 +24,7 @@ LANGUAGES = {
'scenario'
:
'Scenario'
,
'scenario'
:
'Scenario'
,
'scenario_outline'
:
'Scenario Outline'
,
'scenario_outline'
:
'Scenario Outline'
,
},
},
'pt'
:
{
'pt
-br
'
:
{
'examples'
:
'Exemplos|Cenários'
,
'examples'
:
'Exemplos|Cenários'
,
'feature'
:
'Funcionalidade'
,
'feature'
:
'Funcionalidade'
,
'name'
:
'Portuguese'
,
'name'
:
'Portuguese'
,
...
...
tests/unit/test_language.py
View file @
7782b42f
...
@@ -28,16 +28,3 @@ def test_language_is_english_by_default():
...
@@ -28,16 +28,3 @@ def test_language_is_english_by_default():
assert_equals
(
lang
.
scenario
,
'Scenario'
)
assert_equals
(
lang
.
scenario
,
'Scenario'
)
assert_equals
(
lang
.
examples
,
'Examples|Scenarios'
)
assert_equals
(
lang
.
examples
,
'Examples|Scenarios'
)
assert_equals
(
lang
.
scenario_outline
,
'Scenario Outline'
)
assert_equals
(
lang
.
scenario_outline
,
'Scenario Outline'
)
def
test_language_portuguese
():
'Language class supports portuguese through code "pt"'
lang
=
Language
(
'pt'
)
assert_equals
(
lang
.
code
,
'pt'
)
assert_equals
(
lang
.
name
,
'Portuguese'
)
assert_equals
(
lang
.
native
,
u'Português'
)
assert_equals
(
lang
.
feature
,
'Funcionalidade'
)
assert_equals
(
lang
.
scenario
,
u'Cenário|Cenario'
)
assert_equals
(
lang
.
examples
,
'Exemplos|Cenários'
)
assert_equals
(
lang
.
scenario_outline
,
'Esquema do Cenário|Esquema do Cenario'
)
tests/unit/test_language_ptbr.py
0 → 100644
View file @
7782b42f
# -*- coding: utf-8 -*-
# <Lettuce - Behaviour Driven Development for python>
# Copyright (C) <2010> Gabriel Falcão <gabriel@nacaolivre.org>
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
from
nose.tools
import
assert_equals
from
lettuce.core
import
Language
def
test_language_portuguese
():
'Language class supports portuguese through code "pt-br"'
lang
=
Language
(
'pt-br'
)
assert_equals
(
lang
.
code
,
'pt-br'
)
assert_equals
(
lang
.
name
,
'Portuguese'
)
assert_equals
(
lang
.
native
,
u'Português'
)
assert_equals
(
lang
.
feature
,
'Funcionalidade'
)
assert_equals
(
lang
.
scenario
,
u'Cenário|Cenario'
)
assert_equals
(
lang
.
examples
,
'Exemplos|Cenários'
)
assert_equals
(
lang
.
scenario_outline
,
'Esquema do Cenário|Esquema do Cenario'
)
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