| | |
| | | @isTest |
| | | private class LeadIntentionControllerTest { |
| | | |
| | | @testSetup |
| | | static void setUp(){ |
| | | TestDataUtility.CreatePIPolicyConfigurations( new string[]{'Inquiry_form__c'}); |
| | | } |
| | | |
| | | static testMethod void testMethod1() { |
| | | LeadIntentionController.forTest(); |
| | | //医院 |
| | | List<RecordType> rectHp = [select Id from RecordType where IsActive = true and SobjectType = 'Account' and DeveloperName = 'HP']; |
| | | if (rectHp.size() == 0) { |
| | |
| | | inquiryform.Hospital_Name__c = dpt1.Id; |
| | | List<Account> dpecList = [select Id,Department_Class__c from Account where Id =: dpt1.Id]; |
| | | inquiryform.Department_Class__c = dpecList[0].Department_Class__c; |
| | | inquiryform.Status__c ='未跟进'; |
| | | inquiryform.Status__c ='01.未跟进'; |
| | | inquiryform.Company__c ='北京某某某测试公司'; |
| | | inquiryform.Family_Name__c ='靳'; |
| | | inquiryform.Opportunity_Division__c = '询价'; |
| | | inquiryform.Contact_Name__c = contact2.Id; |
| | | inquiryform.Reasons_options__c ='客户不存在'; |
| | | inquiryform.Reasons_options__c ='已经有询价'; |
| | | inquiryform.Phone__c = '13844756322'; |
| | | inquiryform.Product1__c = '超声'; |
| | | inquiryform.Request1__c = '需要报价'; |
| | |
| | | inquiryform.Hospital_Name__c = dpt1.Id; |
| | | List<Account> dpecList = [select Id,Department_Class__c from Account where Id =: dpt1.Id]; |
| | | inquiryform.Department_Class__c = dpecList[0].Department_Class__c; |
| | | inquiryform.Status__c ='未跟进'; |
| | | inquiryform.Status__c ='01.未跟进'; |
| | | inquiryform.Company__c ='北京某某某测试公司'; |
| | | inquiryform.Family_Name__c ='靳'; |
| | | inquiryform.Opportunity_Division__c = '询价'; |
| | | inquiryform.Contact_Name__c = contact2.Id; |
| | | inquiryform.Reasons_options__c ='客户不存在'; |
| | | inquiryform.Reasons_options__c ='已经有询价'; |
| | | inquiryform.Phone__c = '13844756322'; |
| | | inquiryform.Product1__c = '超声'; |
| | | inquiryform.Request1__c = '需要报价'; |