]> Dogcows Code - chaz/graphql-client/blobdiff - t/client.t
rename class attribute to transport_class
[chaz/graphql-client] / t / client.t
index 4775b70036f8c44cc12b10285b9f3bb6a15184b3..1dd0cd425ab19c5f519bee7ab5a63e7a791d173d 100755 (executable)
@@ -14,14 +14,14 @@ use GraphQL::Client;
 use MockTransport;
 
 subtest 'transport' => sub {
-    my $client = GraphQL::Client->new(class => 'http');
-    isa_ok($client->transport, 'GraphQL::Client::http', 'decide transport from class');
+    my $client = GraphQL::Client->new(transport_class => 'http');
+    isa_ok($client->transport, 'GraphQL::Client::http', 'decide transport from transport_class');
 
     $client = GraphQL::Client->new(url => 'https://localhost:4000/graphql');
     isa_ok($client->transport, 'GraphQL::Client::http', 'decide transport from url');
 
-    $client = GraphQL::Client->new(class => 'not a real class');
-    is($client->class, 'not a real class', 'class constructor works');
+    $client = GraphQL::Client->new(transport_class => 'not a real class');
+    is($client->transport_class, 'not a real class', 'transport_class constructor works');
     throws_ok { $client->transport } qr/^Failed to load transport/, 'throws if invalid transport';
 };
 
This page took 0.027236 seconds and 4 git commands to generate.