public function testClamp() { $this->assertTrue(CMathf::clamp(11.0, 0.0, 10.0) === 10.0); $this->assertTrue(CMathf::clamp(-2.0, 0.0, 10.0) === 0.0); $this->assertTrue(CMathf::clamp(5.0, 0.0, 10.0) === 5.0); $this->assertTrue(CMathf::clamp(11, 0, 10) === 10.0); $this->assertTrue(CMathf::clamp(-2, 0, 10) === 0.0); $this->assertTrue(CMathf::clamp(5, 0, 10) === 5.0); }