Skip to content

Instantly share code, notes, and snippets.

@CarsonF
Created July 17, 2015 14:12
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save CarsonF/8212f2b285730af51463 to your computer and use it in GitHub Desktop.
Save CarsonF/8212f2b285730af51463 to your computer and use it in GitHub Desktop.
Dumps pimple container for silex plugin
<?php
use Sorien\Provider\PimpleDumpProvider;
use Symfony\Component\HttpFoundation\Request;
require_once __DIR__ . '/vendor/autoload.php';
$app = new \Bolt\Application();
$request = Request::create('/');
Request::setFactory(function () use ($request) {
return $request;
});
$app->initialize();
$app->register(new PimpleDumpProvider());
$response = $app->handle($request);
$app->terminate($request, $response);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment