repo.or.cz
/
boa.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
importing python metacircular evaluator into git
[boa.git]
/
boa2
/
tests
/
test_name.py
blob
08d5a186d9aa3eed9d0fd8d7b112d214f74fcef4
1
2
from
boa
import
name
3
4
def
test_name_mangling
():
5
names
= [
6
(
"foo_bar_dish"
,
"foo-bar-dish"
),
7
(
"set_foo_bar"
,
"set-foo-bar!"
),
8
(
"null_p"
,
"null?"
),
9
(
"foo_to_bar_1"
,
"foo->bar-1"
)]
10
for
p
,
l
in
names
:
11
l2
=
name
.
py2lisp
(
p
)
12
p2
=
name
.
lisp2py
(
l
)
13
assert
l2
==
l
, (
l2
,
l
)
14
assert
p2
==
p
, (
p2
,
p
)