Browse Source

added bundles and storage directory to dummy laravel test setup.

Taylor Otwell 13 years ago
parent
commit
e0188f70c5
33 changed files with 17 additions and 4 deletions
  1. 5 2
      paths.php
  2. 11 2
      phpunit.php
  3. 0 0
      tests/laravel/application/bundle.php
  4. 0 0
      tests/laravel/application/config/.gitignore
  5. 0 0
      tests/laravel/application/config/application.php
  6. 0 0
      tests/laravel/application/config/auth.php
  7. 0 0
      tests/laravel/application/config/cache.php
  8. 0 0
      tests/laravel/application/config/database.php
  9. 0 0
      tests/laravel/application/config/error.php
  10. 0 0
      tests/laravel/application/config/mimes.php
  11. 0 0
      tests/laravel/application/config/session.php
  12. 0 0
      tests/laravel/application/config/strings.php
  13. 0 0
      tests/laravel/application/controllers/home.php
  14. 0 0
      tests/laravel/application/dashboard/repository.php
  15. 0 0
      tests/laravel/application/language/en/pagination.php
  16. 0 0
      tests/laravel/application/language/en/validation.php
  17. 0 0
      tests/laravel/application/libraries/.gitignore
  18. 0 0
      tests/laravel/application/migrations/.gitignore
  19. 0 0
      tests/laravel/application/models/.gitignore
  20. 0 0
      tests/laravel/application/models/autoloader.php
  21. 0 0
      tests/laravel/application/models/repositories/user.php
  22. 0 0
      tests/laravel/application/models/user.php
  23. 0 0
      tests/laravel/application/routes.php
  24. 0 0
      tests/laravel/application/tasks/.gitignore
  25. 0 0
      tests/laravel/application/views/error/404.php
  26. 0 0
      tests/laravel/application/views/error/500.php
  27. 0 0
      tests/laravel/application/views/home/index.php
  28. 0 0
      tests/laravel/bundles/.gitignore
  29. 0 0
      tests/laravel/storage/cache/.gitignore
  30. 1 0
      tests/laravel/storage/database/.gitignore
  31. 0 0
      tests/laravel/storage/logs/.gitignore
  32. 0 0
      tests/laravel/storage/sessions/.gitignore
  33. 0 0
      tests/laravel/storage/views/.gitignore

+ 5 - 2
paths.php

@@ -16,7 +16,10 @@ if ( ! isset($web)) $web = false;
 // --------------------------------------------------------------
 // Define the directory separator for the environment.
 // --------------------------------------------------------------
-define('DS', DIRECTORY_SEPARATOR);
+if ( ! defined('DS'))
+{
+	define('DS', DIRECTORY_SEPARATOR);
+}
 
 // --------------------------------------------------------------
 // Define the path to the base directory.
@@ -67,7 +70,7 @@ foreach ($paths as $name => $path)
 {
 	if ( ! defined($name))
 	{
-		$path = ($web) ? '../'.$path : $path;
+		if ($web) $path = "../{$path}";
 
 		define($name, realpath($path).DS);
 	}

+ 11 - 2
phpunit.php

@@ -9,13 +9,22 @@
  */
 
 // --------------------------------------------------------------
-// Override the application path if testing Laravel.
+// Define the directory separator for the environment.
+// --------------------------------------------------------------
+define('DS', DIRECTORY_SEPARATOR);
+
+// --------------------------------------------------------------
+// Override the framework paths if testing Laravel.
 // --------------------------------------------------------------
 foreach ($_SERVER['argv'] as $key => $argument)
 {
 	if ($argument == 'laravel' and $_SERVER['argv'][$key - 1] == '--group')
 	{
-		define('APP_PATH', realpath('tests/laravel').DIRECTORY_SEPARATOR);
+		define('APP_PATH', realpath('tests/laravel/application').DS);
+
+		define('BUNDLE_PATH', realpath('tests/laravel/bundles').DS);
+
+		define('STORAGE_PATH', realpath('tests/laravel/storage').DS);
 	}
 }
 

+ 0 - 0
tests/laravel/bundle.php → tests/laravel/application/bundle.php


+ 0 - 0
tests/laravel/config/.gitignore → tests/laravel/application/config/.gitignore


+ 0 - 0
tests/laravel/config/application.php → tests/laravel/application/config/application.php


+ 0 - 0
tests/laravel/config/auth.php → tests/laravel/application/config/auth.php


+ 0 - 0
tests/laravel/config/cache.php → tests/laravel/application/config/cache.php


+ 0 - 0
tests/laravel/config/database.php → tests/laravel/application/config/database.php


+ 0 - 0
tests/laravel/config/error.php → tests/laravel/application/config/error.php


+ 0 - 0
tests/laravel/config/mimes.php → tests/laravel/application/config/mimes.php


+ 0 - 0
tests/laravel/config/session.php → tests/laravel/application/config/session.php


+ 0 - 0
tests/laravel/config/strings.php → tests/laravel/application/config/strings.php


+ 0 - 0
tests/laravel/controllers/home.php → tests/laravel/application/controllers/home.php


+ 0 - 0
tests/laravel/dashboard/repository.php → tests/laravel/application/dashboard/repository.php


+ 0 - 0
tests/laravel/language/en/pagination.php → tests/laravel/application/language/en/pagination.php


+ 0 - 0
tests/laravel/language/en/validation.php → tests/laravel/application/language/en/validation.php


+ 0 - 0
tests/laravel/libraries/.gitignore → tests/laravel/application/libraries/.gitignore


+ 0 - 0
tests/laravel/migrations/.gitignore → tests/laravel/application/migrations/.gitignore


+ 0 - 0
tests/laravel/models/.gitignore → tests/laravel/application/models/.gitignore


+ 0 - 0
tests/laravel/models/autoloader.php → tests/laravel/application/models/autoloader.php


+ 0 - 0
tests/laravel/models/repositories/user.php → tests/laravel/application/models/repositories/user.php


+ 0 - 0
tests/laravel/models/user.php → tests/laravel/application/models/user.php


+ 0 - 0
tests/laravel/routes.php → tests/laravel/application/routes.php


+ 0 - 0
tests/laravel/tasks/.gitignore → tests/laravel/application/tasks/.gitignore


+ 0 - 0
tests/laravel/views/error/404.php → tests/laravel/application/views/error/404.php


+ 0 - 0
tests/laravel/views/error/500.php → tests/laravel/application/views/error/500.php


+ 0 - 0
tests/laravel/views/home/index.php → tests/laravel/application/views/home/index.php


+ 0 - 0
tests/laravel/bundles/.gitignore


+ 0 - 0
tests/laravel/storage/cache/.gitignore


+ 1 - 0
tests/laravel/storage/database/.gitignore

@@ -0,0 +1 @@
+*.sqlite

+ 0 - 0
tests/laravel/storage/logs/.gitignore


+ 0 - 0
tests/laravel/storage/sessions/.gitignore


+ 0 - 0
tests/laravel/storage/views/.gitignore