| | |
| | | |
| | | } |
| | | |
| | | @isTest |
| | | public static void test_applyDate_error2() { |
| | | setupTestData(false); |
| | | |
| | | List<Rental_Apply__c> esList = [SELECT Id FROM Rental_Apply__c]; |
| | | |
| | | PageReference ref = new PageReference('/apex/RentalFixtureSetAssignAgency?pt_recid=' + esList[0].Id); |
| | | Test.setCurrentPage(ref); |
| | | |
| | | RentalFixtureSetAssignAgencyController controller = new RentalFixtureSetAssignAgencyController(); |
| | | Test.startTest(); |
| | | |
| | | controller.init(); |
| | | controller.applyDate(); |
| | | |
| | | List<Apexpages.message> msgs = ApexPages.getMessages(); |
| | | System.assertEquals('请输入[备品预计出货日]', msgs[0].getDetail()); |
| | | |
| | | Test.stopTest(); |
| | | System.debug('init Success'); |
| | | |
| | | } |
| | | |
| | | |
| | | @isTest |
| | | public static void test_assign() { |