nitlanguage
/
nit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
tests: error_syntax errors on `? now
[nit.git]
/
src
/
doc
/
commands
/
tests
/
test_commands.nit
diff --git
a/src/doc/commands/tests/test_commands.nit
b/src/doc/commands/tests/test_commands.nit
index
d91701b
..
24d1593
100644
(file)
--- a/
src/doc/commands/tests/test_commands.nit
+++ b/
src/doc/commands/tests/test_commands.nit
@@
-17,6
+17,7
@@
module test_commands
import commands_base
import frontend
import commands_base
import frontend
+import frontend::parse_examples
# Nitunit test suite specific to commands
class TestCommands
# Nitunit test suite specific to commands
class TestCommands
@@
-31,12
+32,15
@@
class TestCommands
# Default is `$NIT_DIR/tests/test_prog`.
var test_src: String = test_path / "../../../../tests/test_prog" is lazy
# Default is `$NIT_DIR/tests/test_prog`.
var test_src: String = test_path / "../../../../tests/test_prog" is lazy
- # ModelView used for tests
- var test_view: ModelView is noinit
+ # Model used for tests
+ var test_model: Model is noinit
# ModelBuilder used for tests
var test_builder: ModelBuilder is noinit
# ModelBuilder used for tests
var test_builder: ModelBuilder is noinit
+ # Mainmodule used for tests
+ var test_main: MModule is noinit
+
# Initialize test variables
#
# Must be called before test execution.
# Initialize test variables
#
# Must be called before test execution.
@@
-54,13
+58,8
@@
class TestCommands
toolcontext.run_global_phases(mmodules)
var mainmodule = toolcontext.make_main_module(mmodules)
toolcontext.run_global_phases(mmodules)
var mainmodule = toolcontext.make_main_module(mmodules)
- # Build index
- var filters = new ModelFilter(
- private_visibility,
- accept_fictive = false,
- accept_test = false)
-
+ test_main = mainmodule
+ test_model = model
test_builder = modelbuilder
test_builder = modelbuilder
- test_view = new ModelView(model, mainmodule, filters)
end
end
end
end