Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Create the correct file structure in the systems tmp directory #743

Merged
merged 1 commit into from

2 participants

@blainesch
Collaborator

To reproduce the error:

  • Pull a fresh install of the framework
  • Upgrade lithium
  • Install a library
  • Run the library tests through the command line

You can see the exact steps on this traivs build.

@nateabele nateabele merged commit 6cc895b into UnionOfRAD:dev
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
This page is out of date. Refresh to see the latest.
Showing with 13 additions and 1 deletion.
  1. +7 −1 console/lithium.php
  2. +6 −0 tests/cases/console/RequestTest.php
View
8 console/lithium.php
@@ -34,11 +34,17 @@
throw new ErrorException($message);
}
+ $resources = sys_get_temp_dir();
+ $templates = $resources . '/tmp/cache/templates/';
+ if (!is_dir($templates)) {
+ mkdir($resources . '/tmp/cache/templates/', 0777, true);
+ }
+
lithium\core\Libraries::add('lithium');
lithium\core\Libraries::add(basename($working), array(
'default' => true,
'path' => $working,
- 'resources' => sys_get_temp_dir()
+ 'resources' => $resources
));
};
View
6 tests/cases/console/RequestTest.php
@@ -175,6 +175,12 @@ public function testShiftTwo() {
$result = $request->params;
$this->assertEqual($expected, $result);
}
+
+ public function testTemporaryFileStructureExists() {
+ $resources = Libraries::get(true, 'resources');
+ $template = $resources . '/tmp/cache/templates/';
+ $this->assert(is_dir($template));
+ }
}
?>
Something went wrong with that request. Please try again.