DefaultConfigTest::testDisallowsNonwhitelistedType PHP Method

testDisallowsNonwhitelistedType() public method

Test whether sandbox disallows non-whitelisted class type
    public function testDisallowsNonwhitelistedType()
    {
        $this->expectException('PHPSandbox\\Error');
        $this->sandbox->execute(function () {
            return new \stdClass();
        });
    }