Ralph Bean avatar Ralph Bean committed f47ed3c

100% test coverage.

Comments (0)

Files changed (2)

     test_suite = 'nose.collector',
+    tests_require = ['nose', 'BeautifulSoup', 'genshi'],
         # Register your widgets so they can be listed in the WidgetBrowser
+import tw2.core as twc
+def request_local_tst():
+    global _request_local, _request_id
+    if _request_local == None:
+        _request_local = {}
+    try:
+        return _request_local[_request_id]
+    except KeyError:
+        rl_data = {}
+        _request_local[_request_id] = rl_data
+        return rl_data
+twc.core.request_local = request_local_tst
+_request_local = {}
+_request_id = 'whatever'
+def setup():
+    twc.core.request_local = request_local_tst
+    twc.core.request_local()['middleware'] = twc.make_middleware()
+def test_excanvas_resource():
+    from tw2.excanvas import excanvas_js
+    target = "tw2.excanvas.base/static/excanvas.min.js"
+    assert(target in excanvas_js.display())
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.