public function testStackAlwaysContainsStrings() { $context = new Context(); $context->set(123); $context->push(true); $this->assertEquals(["123", "1"], $context->toArray()); $context->fromArray([123, true]); $this->assertEquals(["123", "1"], $context->toArray()); }
/** * @inheritdoc */ public function holdsFor(Context $context) { return $this->language->evaluate($this->expression, $context->toArray()) === true; }