| | |
| | | @isTest |
| | | private class PAEDecisionRecordControllerTest { |
| | | static testMethod void myUnitTest() { |
| | | |
| | | /*static testMethod void myUnitTest() { |
| | | Profile p = [select Id from Profile where id =:System.Label.ProfileId_SystemAdmin]; |
| | | // ユーザー作成 |
| | | User hpOwner = new User(Job_Category__c = '销售服务', Test_staff__c = true, LastName = 'hp', FirstName = 'owner', Alias = 'hp', CommunityNickname = 'hpOwner', Email = 'olympus_hpowner@sunbridge.com', Username = 'olympus_hpowner@sunbridge.com', IsActive = true, EmailEncodingKey = 'ISO-2022-JP', TimeZoneSidKey = 'Asia/Tokyo', LocaleSidKey = 'ja_JP', LanguageLocaleKey = 'ja', ProfileId = p.id); |
| | |
| | | controller3.InsertMoreRows(); |
| | | controller3.SaveAndClose(); |
| | | // System.Test.stopTest(); |
| | | } |
| | | }*/ |
| | | static testMethod void myUnitTest2() { |
| | | List<RecordType> rectCo = [select Id from RecordType where IsActive = true and SobjectType = 'Account' and Name = '病院']; |
| | | if (rectCo.size() == 0) { |
| | |
| | | System.Test.setCurrentPage(page); |
| | | PAEDecisionRecordController controller = new PAEDecisionRecordController(new ApexPages.StandardController(repair1)); |
| | | controller.CancelineFlag = 3; |
| | | |
| | | controller.test();// 20220804 ljh add |
| | | // 初始化测试 |
| | | controller.init(); |
| | | controller.paedRecordDetailView[0].paedrdd.PAED_ManagementCode__c = 'T001'; |
| | |
| | | // 初始化测试 |
| | | controller2.init(); |
| | | |
| | | controller2.paedRecordDetailView[0].paedrdd.PAED_ManagementCode__c = 'T002'; |
| | | // 20220725 ljh update start |
| | | // controller2.paedRecordDetailView[0].paedrdd.PAED_ManagementCode__c = 'T002'; |
| | | controller2.paedRecordDetailView[0].paedrdd.PAED_ManagementCode__c = 'T002,T220525'; |
| | | // 20220725 ljh update end |
| | | controller2.paedRecordDetailView[0].paedrdd.PAE_Judge__c = 'Unknown'; |
| | | controller2.paedRecordDetailView[0].paedrdd.PAED_Status__c = '有效'; |
| | | controller2.paedRecordDetailView[0].paedrdd.PAED_Reappear_Result__c = '不再現'; |
| | |
| | | controller3.InsertMoreRows(); |
| | | controller3.SaveAndClose(); |
| | | } |
| | | static testMethod void test002() { |
| | | /*static testMethod void test002() { |
| | | Profile p = [select Id from Profile where id =:System.Label.ProfileId_SystemAdmin]; |
| | | // ユーザー作成 |
| | | User hpOwner = new User(Job_Category__c = '销售服务', Test_staff__c = true, LastName = 'hp', FirstName = 'owner', Alias = 'hp', CommunityNickname = 'hpOwner', Email = 'olympus_hpowner@sunbridge.com', Username = 'olympus_hpowner@sunbridge.com', IsActive = true, EmailEncodingKey = 'ISO-2022-JP', TimeZoneSidKey = 'Asia/Tokyo', LocaleSidKey = 'ja_JP', LanguageLocaleKey = 'ja', ProfileId = p.id); |
| | |
| | | controller3.InsertMoreRows(); |
| | | controller3.sendToSAP(); |
| | | // System.Test.stopTest(); |
| | | } |
| | | }*/ |
| | | |
| | | static testMethod void test003() { |
| | | Profile p = [select Id from Profile where id =:System.Label.ProfileId_SystemAdmin]; |
| | |
| | | // controller3.sendToSAP(); |
| | | // System.Test.stopTest(); |
| | | } |
| | | static testMethod void test004() { |
| | | /*static testMethod void test004() { |
| | | Profile p = [select Id from Profile where id =:System.Label.ProfileId_SystemAdmin]; |
| | | // ユーザー作成 |
| | | User hpOwner = new User(Job_Category__c = '销售服务', Test_staff__c = true, LastName = 'hp', FirstName = 'owner', Alias = 'hp', CommunityNickname = 'hpOwner', Email = 'olympus_hpowner@sunbridge.com', Username = 'olympus_hpowner@sunbridge.com', IsActive = true, EmailEncodingKey = 'ISO-2022-JP', TimeZoneSidKey = 'Asia/Tokyo', LocaleSidKey = 'ja_JP', LanguageLocaleKey = 'ja', ProfileId = p.id); |
| | |
| | | controller3.InsertMoreRows(); |
| | | controller3.sendToSAP(); |
| | | // System.Test.stopTest(); |
| | | } |
| | | }*/ |
| | | |
| | | |
| | | |