test/cxx/ApplicationPool2/SmartSpawnerTest.cpp in passenger-4.0.20 vs test/cxx/ApplicationPool2/SmartSpawnerTest.cpp in passenger-4.0.21
- old
+ new
@@ -33,22 +33,22 @@
setLogLevel(DEFAULT_LOG_LEVEL);
unlink("stub/wsgi/passenger_wsgi.pyc");
PipeWatcher::onData = PipeWatcher::DataCallback();
}
- shared_ptr<SmartSpawner> createSpawner(const Options &options, bool exitImmediately = false) {
+ boost::shared_ptr<SmartSpawner> createSpawner(const Options &options, bool exitImmediately = false) {
char buf[PATH_MAX + 1];
getcwd(buf, PATH_MAX);
vector<string> command;
command.push_back("ruby");
command.push_back(string(buf) + "/support/placebo-preloader.rb");
if (exitImmediately) {
command.push_back("exit-immediately");
}
- return make_shared<SmartSpawner>(bg.safe,
+ return boost::make_shared<SmartSpawner>(bg.safe,
*resourceLocator,
generation,
command,
options);
}
@@ -75,11 +75,11 @@
// restart it and try again.
Options options = createOptions();
options.appRoot = "stub/rack";
options.startCommand = "ruby\t" "start.rb";
options.startupFile = "start.rb";
- shared_ptr<SmartSpawner> spawner = createSpawner(options);
+ boost::shared_ptr<SmartSpawner> spawner = createSpawner(options);
process = spawner->spawn(options);
process->requiresShutdown = false;
kill(spawner->getPreloaderPid(), SIGTERM);
// Give it some time to exit.
@@ -97,11 +97,11 @@
Options options = createOptions();
options.appRoot = "stub/rack";
options.startCommand = "ruby\t" "start.rb";
options.startupFile = "start.rb";
setLogLevel(-1);
- shared_ptr<SmartSpawner> spawner = createSpawner(options, true);
+ boost::shared_ptr<SmartSpawner> spawner = createSpawner(options, true);
try {
process = spawner->spawn(options);
process->requiresShutdown = false;
fail("SpawnException expected");
} catch (const SpawnException &) {
@@ -167,10 +167,10 @@
process = spawner.spawn(options);
process->requiresShutdown = false;
fail("SpawnException expected");
} catch (const SpawnException &e) {
ensure_equals(e.getErrorKind(),
- SpawnException::PRELOADER_STARTUP_PROTOCOL_ERROR);
+ SpawnException::PRELOADER_STARTUP_ERROR);
ensure(e.getErrorPage().find("hello world\n") != string::npos);
}
}
TEST_METHOD(84) {