aboutsummaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
Diffstat (limited to 't')
-rw-r--r--t/40-response.t16
1 files changed, 9 insertions, 7 deletions
diff --git a/t/40-response.t b/t/40-response.t
index c401378..a45594a 100644
--- a/t/40-response.t
+++ b/t/40-response.t
@@ -1,8 +1,10 @@
use lib 'lib';
use Test;
use JSON::Fast;
-use Matrix::Response;
-plan 2;
+plan 3;
+
+use-ok 'Matrix::Client::Response';
+use Matrix::Client::Response;
subtest 'Sync', {
plan 7;
@@ -11,10 +13,10 @@ subtest 'Sync', {
if $test-file.IO.f {
$data = from-json($test-file.IO.slurp);
- lives-ok { Matrix::Response::Sync.new($test-file.IO.slurp) }, 'Sync.new accepts Str';
- lives-ok { Matrix::Response::Sync.new($data) }, 'Sync.new accepts Associative';
+ lives-ok { Matrix::Client::Response::Sync.new($test-file.IO.slurp) }, 'Sync.new accepts Str';
+ lives-ok { Matrix::Client::Response::Sync.new($data) }, 'Sync.new accepts Associative';
- my $res = Matrix::Response::Sync.new($data);
+ my $res = Matrix::Client::Response::Sync.new($data);
can-ok $res, 'joined-rooms', 'can .joined-rooms';
can-ok $res, 'presence', 'can .presence';
@@ -30,9 +32,9 @@ subtest 'Sync', {
subtest 'MediaStore', {
plan 4;
my %config = 'm.upload.size' => 5000;
- my $config-response = Matrix::Response::MediaStore::Config.new(%config);
+ my $config-response = Matrix::Client::Response::MediaStore::Config.new(%config);
- isa-ok $config-response, Matrix::Response::MediaStore::Config;
+ isa-ok $config-response, Matrix::Client::Response::MediaStore::Config;
can-ok $config-response, 'upload-size';
isa-ok $config-response.upload-size, Int;
is $config-response.upload-size, %config<m.upload.size>, 'correct upload size';