Skip to content

Commit

Permalink
Merge pull request #5 from tyx/fix/scrutinizer
Browse files Browse the repository at this point in the history
Small fixes
  • Loading branch information
tyx committed Feb 17, 2015
2 parents 4000fd3 + d97e698 commit 8f1fd9c
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/Json/JsonSchema.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public function resolve(RefResolver $resolver)
throw new \LogicException('Cannot resolve JsonSchema without uri parameter');
}

$resolver->resolve($this->encode(false), $this->uri);
$resolver->resolve($this->getRawContent(), $this->uri);

return $this;
}
Expand Down
6 changes: 3 additions & 3 deletions src/RestApiContext.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ public function theResponseCodeShouldBe($code)
{
$expected = intval($code);
$actual = intval($this->response->getStatusCode());
$this->asserter->variable($actual)->isEqualTo($code);
$this->asserter->variable($actual)->isEqualTo($expected);
}

/**
Expand All @@ -91,8 +91,8 @@ public function iAddHeaderEqualTo($headerName, $headerValue)
public function iSetBasicAuthenticationWithAnd($username, $password)
{
$this->removeHeader('Authorization');
$this->authorization = base64_encode($username . ':' . $password);
$this->addHeader('Authorization', 'Basic ' . $this->authorization);
$authorization = base64_encode($username . ':' . $password);
$this->addHeader('Authorization', 'Basic ' . $authorization);
}

/**
Expand Down
2 changes: 1 addition & 1 deletion tests/Units/Json/JsonSchema.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public function test_should_resolve_with_uri()
)
->mock($resolver)
->call('resolve')
->withArguments('{}', 'file://test')
->withArguments(new \stdClass, 'file://test')
->once()

->object($result)
Expand Down

0 comments on commit 8f1fd9c

Please sign in to comment.