Oops, I am sorry. It is mistake of my environment. I have worked unit tests
in the virtual environment which installed Ryu.

Hmm… It will not become ImportError if importing app_manager is moved
before importing Datapath. But I can not understand well why it becomes so…

2013/9/3 FUJITA Tomonori <[email protected]>

> On Tue,  3 Sep 2013 11:20:52 +0900
> Satoshi Kobayashi <[email protected]> wrote:
>
> > OFPP_NONE in OpenFlow 1.0 is equivalent to OFPP_ANY in OpenFlow 1.1+.
> >
> > Signed-off-by: Satoshi Kobayashi <[email protected]>
> > ---
> >  ryu/controller/controller.py                 |    6 ++-
> >  ryu/tests/unit/controller/test_controller.py |   55
> ++++++++++++++++++++++++++
> >  2 files changed, 60 insertions(+), 1 deletions(-)
> >  create mode 100644 ryu/tests/unit/controller/__init__.py
> >  create mode 100644 ryu/tests/unit/controller/test_controller.py
>
> Thanks. I got the following error about the unittest:
>
> ERROR: Failure: ImportError (cannot import name Datapath)
> ----------------------------------------------------------------------
> Traceback (most recent call last):
>   File
>   "/Users/fujita/git/ryu/.venv/lib/python2.7/site-packages/nose/loader.py",
>   line 413, in loadTestsFromName
>     addr.filename, addr.module)
>   File
>
> "/Users/fujita/git/ryu/.venv/lib/python2.7/site-packages/nose/importer.py",
>   line 47, in importFromPath
>     return self.importFromDir(dir_path, fqname)
>   File
>
> "/Users/fujita/git/ryu/.venv/lib/python2.7/site-packages/nose/importer.py",
>   line 94, in importFromDir
>     mod = load_module(part_fqname, fh, filename, desc)
>   File
>   "/Users/fujita/git/ryu/ryu/tests/unit/controller/test_controller.py",
>   line 22, in <module>
>     from ryu.controller.controller import Datapath
>   File "/Users/fujita/git/ryu/ryu/controller/controller.py", line 26,
>   in <module>
>     import ryu.base.app_manager
>   File "/Users/fujita/git/ryu/ryu/base/app_manager.py", line 23, in
>   <module>
>     from ryu.controller.controller import Datapath
> ImportError: cannot import name Datapath
>
>


-- 
Satoshi Kobayashi <[email protected]>
------------------------------------------------------------------------------
Learn the latest--Visual Studio 2012, SharePoint 2013, SQL 2012, more!
Discover the easy way to master current and previous Microsoft technologies
and advance your career. Get an incredible 1,500+ hours of step-by-step
tutorial videos with LearnDevNow. Subscribe today and save!
http://pubads.g.doubleclick.net/gampad/clk?id=58040911&iu=/4140/ostg.clktrk
_______________________________________________
Ryu-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ryu-devel

Reply via email to