public function testGenerateToken() { $token = $this->tokenProcessor->generateToken($this->request); $token2 = $this->tokenProcessor->generateToken($this->request); $this->assertNotEmpty($token); $this->assertNotEmpty($token2); $this->assertNotEquals($token, $token2); }
/** * <p>Save a new transaction token in the user's current session, creating * a new session if necessary.</p> * * @param \Symfony\Component\HttpFoundation\Request request The actionKernel request we are processing */ protected function saveToken(Request $request) { $token = \Phruts\Util\TokenProcessor::getInstance(); // not application scope $token->saveToken($request); }