public function testGetPercentageStartsProvidedEmail() { $total = 60; $num = (int) rand(1, 50); $expected = round($num / $total * 100, AnalyticsExport::PERCENTAGE_PRECISION); $this->assertInstanceOf(AnalyticsExport::class, $this->instance->setStarts($total)); $this->assertEquals($total, $this->instance->getStarts()); $this->assertInstanceOf(AnalyticsExport::class, $this->instance->setProvidedEmailAddress($num)); $this->assertEquals($num, $this->instance->getProvidedEmailAddress()); $this->assertEquals($expected, $this->instance->getPercentageStartsProvidedEmail()); }