public function getValue() { if (null !== $this->value) { return $this->value; } return $this->defaultValue; }
public function testDefaultValue() { $opt = new Option('z'); $opt->defaultValue(10); $this->assertEquals(10, $opt->getValue()); $this->assertEquals('-z[=10]', $opt->renderReadableSpec(true)); }