import { getTestAlertData } from '../../../common/lib' ; import { FtrProviderContext } from '../../../../common/ftr_provider_context' ; export default function emailTest ( { getService } ) { const supertest = getService ( 'supertest' ) ; describe ( 'create gold noop alert' , ( ) => { it ( 'should return 403 when creating an gold alert' , async ( ) => { await supertest . post ( `/api/alerting/rule` ) . set ( 'kbn-xsrf' , 'foo' ) . send ( getTestAlertData ( { rule_type_id : 'test.gold.noop' } ) ) . expect ( 403 , { statusCode : 403 , error : 'Forbidden' , message : 'Rule test.gold.noop is disabled because it requires a Gold license. Go to License Management to view upgrade options.' , } ) ; } ) ; } ) ; }