TestSessionStubCodeWriter
class TestSessionStubCodeWriter (View source)
Writes PHP to a file which can be included in SilverStripe runs on existence.
The generated file is included in page execution through TestSessionRequestFilter.
Properties
| protected | bool | $debug | ||
| protected | string | $filePath | 
Methods
                    public                                                                            
                
                    write(string $php, bool $eval = true)
        
                                            
                
            Writes arbitrary PHP code to $filePath for later inclusion.
Details
        
                            
    __construct($filePath = null)
        
    
    No description
        
                            
    write(string $php, bool $eval = true)
        
    
    Writes arbitrary PHP code to $filePath for later inclusion.
Creates the file if it doesn't exist. Adds debug information about the origin of this code if $debug is set.
        
                            
    reset()
        
    
    No description
        
                            
    getFilePath()
        
    
    No description
        
                            
    getDebug()
        
    
    No description
        
                            
    setDebug($debug)
        
    
    No description