Improve UnexpectedValueException error message, add testcase. #310

Closed
wants to merge 1 commit into
from

Conversation

Projects
None yet
4 participants
Contributor

JamesGuthrie commented Dec 19, 2013

UnexpectedValueException::proxyDirectoryNotWritable() provides
information as to which directory was unwritable.

A TestCase is provided for the proxyDirectoryNotWritable() function.

@JamesGuthrie JamesGuthrie Improve UnexpectedValueException error message, add testcase.
UnexpectedValueException::proxyDirectoryNotWritable() provides
information as to which directory was unwritable.

A TestCase is provided for the proxyDirectoryNotWritable() function.
7c611f0

Hello,

thank you for creating this pull request. I have automatically opened an issue
on our Jira Bug Tracker for you. See the issue link:

http://www.doctrine-project.org/jira/browse/DCOM-226

We use Jira to track the state of pull requests and the versions they got
included in.

@Ocramius Ocramius commented on the diff Dec 19, 2013

...e/Common/Proxy/Exception/UnexpectedValueException.php
{
- return new self('Your proxy directory must be writable');
+ return new self(sprintf('Your proxy directory: %s must be writable', $proxyDirectory));
@Ocramius

Ocramius Dec 19, 2013

Owner

Enclose %s like "%s". Also, no colon

@Ocramius Ocramius commented on the diff Dec 19, 2013

...ctrine/Tests/Common/Proxy/ProxyClassGeneratorTest.php
@@ -183,6 +183,23 @@ public function testNoConfigDirThrowsException()
new ProxyGenerator(null, null);
}
+ public function testProxyDirNotWritableThrowsException()
@Ocramius

Ocramius Dec 19, 2013

Owner

This test is not really necessary, and will fail on windows machines I think (not sure)

@JamesGuthrie

JamesGuthrie Dec 19, 2013

Contributor

Should I remove it then?

Contributor

JamesGuthrie commented Dec 19, 2013

I have closed this pull request and opened #312 which excludes the test case (which doesn't work in Windows).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment