summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorBozhidar Batsov <bozhidar@batsov.com>2016-02-28 12:09:07 +0200
committerBozhidar Batsov <bozhidar@batsov.com>2016-02-28 12:09:07 +0200
commit6cbcf4eef48450c87669b2ed61e6d73ed6c510dd (patch)
tree5e530cb9dc574cc02eb114c19498ab69aa8122df /test
parent83e15cb331f07c6223359417c5773560a3b3ab99 (diff)
Make sure cider-open-classpath-entry doesn't blow up in the absence of a
connection or the classpath op
Diffstat (limited to 'test')
-rw-r--r--test/cider-classpath-tests.el8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/cider-classpath-tests.el b/test/cider-classpath-tests.el
index 82542218..8173ab06 100644
--- a/test/cider-classpath-tests.el
+++ b/test/cider-classpath-tests.el
@@ -10,3 +10,11 @@
(ert-deftest cider-classpath-unsupported-op ()
(noflet ((cider-ensure-op-supported (op) nil))
(should-error (cider-classpath) :type 'user-error)))
+
+(ert-deftest cider-open-classpath-entry-not-connected ()
+ (noflet ((cider-connected-p () nil))
+ (should-error (cider-open-classpath-entry) :type 'user-error)))
+
+(ert-deftest cider-open-classpath-entry-unsupported-op ()
+ (noflet ((cider-ensure-op-supported (op) nil))
+ (should-error (cider-open-classpath-entry) :type 'user-error)))