Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
flatlatex
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
leger
flatlatex
Commits
943caea2
Commit
943caea2
authored
Jan 01, 2017
by
Jean-Benoist Leger
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tests
parent
35b11360
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
66 additions
and
0 deletions
+66
-0
flatlatex/tests/__init__.py
flatlatex/tests/__init__.py
+0
-0
flatlatex/tests/test_data_consistancy.py
flatlatex/tests/test_data_consistancy.py
+65
-0
setup.py
setup.py
+1
-0
No files found.
flatlatex/tests/__init__.py
0 → 100644
View file @
943caea2
flatlatex/tests/test_data_consistancy.py
0 → 100644
View file @
943caea2
from
..
import
data
from
..
import
parser
def
test_known_fracts
():
assert
type
(
data
.
known_fracts
)
is
dict
for
k
,
v
in
data
.
known_fracts
.
items
():
assert
type
(
k
)
is
tuple
assert
len
(
k
)
==
2
assert
all
([
type
(
x
)
is
str
for
x
in
k
])
assert
type
(
v
)
is
str
def
test_transliteration_consistancy
():
for
d
in
(
data
.
subscript
,
data
.
superscript
,
data
.
bb
,
data
.
bf
,
data
.
cal
,
data
.
frak
,
data
.
it
,
data
.
mono
,
):
assert
type
(
d
)
is
dict
for
k
,
v
in
d
.
items
():
assert
type
(
k
)
is
str
assert
type
(
v
)
is
str
def
test_symbols_consistancy
():
assert
type
(
data
.
symbols
)
is
dict
for
k
,
v
in
data
.
symbols
.
items
():
assert
type
(
k
)
is
str
out
=
parser
.
parse
(
k
)
assert
len
(
out
)
==
1
assert
out
[
0
][
0
]
==
'cmd'
assert
type
(
v
)
is
str
def
test_combining_consistancy
():
assert
type
(
data
.
combinings
)
is
dict
for
k
,
v
in
data
.
combinings
.
items
():
assert
type
(
k
)
is
str
out
=
parser
.
parse
(
k
)
assert
len
(
out
)
==
1
assert
out
[
0
][
0
]
==
'cmd'
assert
type
(
v
)
is
tuple
assert
len
(
v
)
==
2
assert
all
([
type
(
x
)
is
str
for
x
in
v
])
def
test_newcommands_consistancy
():
assert
type
(
data
.
newcommands
)
is
tuple
for
k
in
data
.
newcommands
:
parsed
=
parser
.
parse
(
k
)
assert
len
(
parsed
)
in
(
3
,
6
)
assert
parsed
[
0
][
0
]
==
'cmd'
assert
parsed
[
0
][
1
]
in
(
r
'\newcommand'
,
r
'\renewcommand'
,
r
'\def'
)
if
len
(
parsed
)
==
6
:
assert
parsed
[
2
]
==
(
'char'
,
'['
)
assert
parsed
[
4
]
==
(
'char'
,
']'
)
assert
type
(
parsed
[
3
][
0
])
is
str
a
=
int
(
parsed
[
3
][
1
])
assert
a
>=
0
setup.py
View file @
943caea2
...
...
@@ -100,6 +100,7 @@ setup(
# for example:
# $ pip install -e .[dev,test]
extras_require
=
{
'test'
:
[
'pytest'
],
},
# If there are data files included in your packages that need to be
...
...
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