Test Omar senouci (v2)

Revision 2 of this benchmark created on


Test runner

Ready to run.

Testing in
TestOps/sec
Code Omar
const featureToggle = () => true

const policyHasExtendedGradeCheckProductCode = productCode => {
	if(!featureToggle){
		return false;
	}
    switch (productCode) {
      case 'BONI':
      case 'GRDCK':
      case 'CA2':
        return true
      default:
        return false
    }
 }
 
 policyHasExtendedGradeCheckProductCode("CA2")
ready
Code Clémentine
const featureToggle = () => true

const policyHasExtendedGradeCheckProductCode = productCode => featureToggle('tmp-extended-grade-check') && ['BONI', 'GRDCK', 'CA2'].includes(productCode)

policyHasExtendedGradeCheckProductCode('CA2')
ready

Revisions

You can edit these tests or add more tests to this page by appending /edit to the URL.