summaryrefslogtreecommitdiff
path: root/t/50-exception.t
diff options
context:
space:
mode:
authorMatias Linares <matiaslina@gmail.com>2018-08-04 18:52:16 -0300
committerMatias Linares <matiaslina@gmail.com>2018-08-04 18:52:16 -0300
commitf3f383db83504fd6e921b7899bbe893575625d45 (patch)
tree51ba10f1ff046c8ed0370395d872767136418cbc /t/50-exception.t
parent305bb42b3311c8ac9d04235e5548ae9b67de06ac (diff)
downloadperl6-matrix-client-f3f383db83504fd6e921b7899bbe893575625d45.tar.gz
Add tests
Diffstat (limited to 't/50-exception.t')
-rw-r--r--t/50-exception.t12
1 files changed, 12 insertions, 0 deletions
diff --git a/t/50-exception.t b/t/50-exception.t
new file mode 100644
index 0000000..d252153
--- /dev/null
+++ b/t/50-exception.t
@@ -0,0 +1,12 @@
+use lib 'lib';
+use Test;
+use Matrix::Client;
+use Matrix::Client::Exception;
+
+plan 1;
+
+my $c = Matrix::Client.new(:home-server<https://matrix.org>);
+
+throws-like {
+ $c.get('/unknown-endpoint');
+}, X::Matrix::Response, 'Unknown endpoint throws exception';