Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
beat.editor
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
beat
beat.editor
Commits
1a8dbdeb
Commit
1a8dbdeb
authored
6 years ago
by
Samuel GAIST
Browse files
Options
Downloads
Patches
Plain Diff
[tests] Remove nose dependency
beat.editor will be using pytest
parent
97e6d088
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
beat/editor/test/test_utils.py
+7
-6
7 additions, 6 deletions
beat/editor/test/test_utils.py
with
7 additions
and
6 deletions
beat/editor/test/test_utils.py
+
7
−
6
View file @
1a8dbdeb
...
@@ -25,11 +25,12 @@
...
@@ -25,11 +25,12 @@
# #
# #
###############################################################################
###############################################################################
# test the utils.py file
"""
# (mostly python file generation via jinja2 templates)
Test the utils.py file
"""
import
os
import
os
import
nose.tools
import
pkg_resources
import
pkg_resources
from
..
import
utils
from
..
import
utils
...
@@ -41,7 +42,7 @@ def test_generate_empty_database():
...
@@ -41,7 +42,7 @@ def test_generate_empty_database():
database
=
utils
.
generate_database
()
database
=
utils
.
generate_database
()
with
open
(
os
.
path
.
join
(
DATA_PATH
,
"
empty_database.py
"
))
as
db_file
:
with
open
(
os
.
path
.
join
(
DATA_PATH
,
"
empty_database.py
"
))
as
db_file
:
empty_db
=
db_file
.
read
()
empty_db
=
db_file
.
read
()
nose
.
tools
.
eq_
(
database
,
empty_db
)
assert
database
==
empty_db
def
test_generate_empty_algorithm
():
def
test_generate_empty_algorithm
():
...
@@ -52,11 +53,11 @@ def test_generate_empty_algorithm():
...
@@ -52,11 +53,11 @@ def test_generate_empty_algorithm():
algorithm
=
utils
.
generate_algorithm
(
alg
[
"
contents
"
])
algorithm
=
utils
.
generate_algorithm
(
alg
[
"
contents
"
])
with
open
(
os
.
path
.
join
(
DATA_PATH
,
"
empty_algorithm.py
"
))
as
db_file
:
with
open
(
os
.
path
.
join
(
DATA_PATH
,
"
empty_algorithm.py
"
))
as
db_file
:
empty_alg
=
db_file
.
read
()
empty_alg
=
db_file
.
read
()
nose
.
tools
.
eq_
(
algorithm
,
empty_alg
)
assert
algorithm
==
empty_alg
def
test_generate_empty_library
():
def
test_generate_empty_library
():
library
=
utils
.
generate_library
()
library
=
utils
.
generate_library
()
with
open
(
os
.
path
.
join
(
DATA_PATH
,
"
empty_library.py
"
))
as
db_file
:
with
open
(
os
.
path
.
join
(
DATA_PATH
,
"
empty_library.py
"
))
as
db_file
:
empty_lib
=
db_file
.
read
()
empty_lib
=
db_file
.
read
()
nose
.
tools
.
eq_
(
library
,
empty_lib
)
assert
library
==
empty_lib
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment