public function __toString() { if ($this->type == null) { return null; } return JobsUtil::resolveStringContentByType($this->type); }
public function testResolveStringContentByType() { $content = JobsUtil::resolveStringContentByType('Monitor'); $this->assertEquals('Monitor Job', $content); $content = JobsUtil::resolveStringContentByType('NotRealJob'); $this->assertEquals('(Unnamed)', $content); }