@isTest private class ScheduleUrlHardCodeProcessingTest { @TestSetup static void TestSetup(){ QuoteIrai__c quote = new QuoteIrai__c(); quote.Note__c = '意向:https://ocsm--c.ap0.visual.force.com/00Q1000000Szocz'; insert quote; Rental_Apply__c apply = new Rental_Apply__c(); apply.Response__c = '****** 朱 炳西 2016/08/20 10:21 ********* To:OCM_Asset@olympus.com.cn*** Cc:赵 阳郭 san,您好!由于CV170只能配S7主机摄像头,所以摄像头不能改变,继续等待排队。UHI-E可以用替换UHI-3。谢谢!****** 郭 丽 2016/08/19 13:47 ********* To:朱 炳西,朱 炳西(操作者)*** Cc:杨 东宁朱先生,您好!您申请的备品只有YQT-781,WA53000A有库存对应,其他的均无库存需要排队。UHI-E无保有,是否可以用UHI-3来替代?OTV-S7H-NA-12E无保有,是否可以用OTV-S7ProH-HD-12E来替代?以上,谢谢!备品借出申请链接: https://c.ap0.visual.force.com/a0t1000000B0LFmAAN'; insert apply; Task task = new Task(); task.Description = 'N4492780 1N4479780 1第一经销商名称:四川沐兮商贸有限公司报价比例:0.00意向:https://ocsm--c.vf.force.com/00QIR00000YIERh2AP客户:https://ocsm--c.vf.force.com/001IR00001o225sYAA第一经销商:https://ocsm--c.vf.force.com/00110000011tY1UAAU招标项目:https://ocsm--c.vf.force.com/undefined'; insert task; Consum_Apply__c conApply = new Consum_Apply__c(); conApply.Response__c = '****** 王伟波 2023/12/08 9:13 ********* To:徐兆希,徐兆希(操作者)*** Cc:ocm_assetsh@olympus.com.cn,包文丽徐San您好,借用大量耗材的原因是什么,如果有领导同意的邮件,请协助上传领导同意邮件在附件上,谢谢!耗材借出申请链接:https://ocsm--c.vf.force.com/a3iIR000002Yj4sYAC'; insert conApply; } @IsTest static void testSchedule(){ QuoteIrai__c quote = [SELECT Id, Note__c FROM QuoteIrai__c][0]; Rental_Apply__c apply = [SELECT Id, Response__c FROM Rental_Apply__c][0]; Task task = [SELECT Id, Description FROM Task][0]; Consum_Apply__c conApply = [SELECT Id, Response__c FROM Consum_Apply__c][0]; Test.startTest(); ScheduleUrlHardCodeProcessing bdaSch = new ScheduleUrlHardCodeProcessing(); SchedulableContext sc; bdaSch.execute(sc); BatchUrlHardCodeProcessing batchHard = new BatchUrlHardCodeProcessing(''); Test.stopTest(); } }