@isTest public with sharing class AccountToTMSInfoTest { static testMethod void testInit(){ Address_Level__c address = new Address_Level__c(Level1_Code__c = 'CN-01',Name='北京市'); insert address; // 病院を作る Account hospital = new Account(); hospital.recordtypeId = [Select Id FROM RecordType WHERE IsActive = true and SobjectType = 'Account' and DeveloperName = 'HP'].id; hospital.Name = 'test hospital'; hospital.Is_Active__c = '有效'; hospital.TradeComplianceStatus__c = '警示名单'; hospital.State_Master__c = address.Id; insert hospital; } }