From b9d31ae490868d9c2db462f81a535296e6bf12b6 Mon Sep 17 00:00:00 2001 From: Stewart Anderson Date: Tue, 2 Apr 2024 10:57:55 +0100 Subject: [PATCH] Formatting updates Updated LWC, Aura and Apex to API v60.0 --- .gitignore | 1 + .../default/classes/AlertBannerController.cls | 2 +- .../AlertBannerController.cls-meta.xml | 2 +- .../classes/AlertBannerControllerTest.cls | 5 +-- .../AlertBannerControllerTest.cls-meta.xml | 2 +- .../default/classes/AnimalActionRLClass2.cls | 8 ++--- .../classes/AnimalActionRLClass2.cls-meta.xml | 2 +- .../classes/AnimalActionRLClass2Test.cls | 2 +- .../AnimalActionRLClass2Test.cls-meta.xml | 2 +- .../AnimalShelterFieldsetController.cls | 4 +-- .../AnimalShelterFieldsetControllerTest.cls | 6 ++-- ...ShelterFieldsetControllerTest.cls-meta.xml | 2 +- .../AnimalShelterGetCustomSettings.cls | 6 ++-- ...nimalShelterGetCustomSettings.cls-meta.xml | 2 +- .../AnimalShelterGetCustomSettingsTest.cls | 8 ++--- ...lShelterGetCustomSettingsTest.cls-meta.xml | 2 +- ...nimalCloneDatatableController.cls-meta.xml | 2 +- .../FSCAnimalCloneDatatableControllerTest.cls | 12 +++---- ...lCloneDatatableControllerTest.cls-meta.xml | 2 +- .../FSC_FileUploadPreviewController.cls | 2 +- ...C_FileUploadPreviewController.cls-meta.xml | 2 +- .../FSC_FileUploadPreviewControllerTest.cls | 4 +-- ...leUploadPreviewControllerTest.cls-meta.xml | 2 +- .../main/default/classes/GetRandomNumber.cls | 33 ++++++++++--------- .../classes/GetRandomNumber.cls-meta.xml | 2 +- .../default/classes/GetRandomNumberTest.cls | 8 ++--- .../classes/GetRandomNumberTest.cls-meta.xml | 2 +- .../default/classes/LocationController.cls | 8 ++--- .../classes/LocationController.cls-meta.xml | 2 +- .../classes/LocationControllerTest.cls | 13 ++++---- .../LocationControllerTest.cls-meta.xml | 2 +- .../classes/MockW3WResponseGenerator.cls | 4 +-- .../MockW3WResponseGenerator.cls-meta.xml | 2 +- .../classes/MockW3WResponseGeneratorTest.cls | 4 +-- .../MockW3WResponseGeneratorTest.cls-meta.xml | 2 +- .../classes/ProfilePictureController.cls | 16 ++++----- .../ProfilePictureController.cls-meta.xml | 2 +- .../classes/ProfilePictureControllerTest.cls | 11 ++++--- .../ProfilePictureControllerTest.cls-meta.xml | 2 +- .../default/classes/W3WInvocableCallout.cls | 12 +++---- .../classes/W3WInvocableCallout.cls-meta.xml | 2 +- .../classes/W3WInvocableCalloutTest.cls | 11 ++++--- .../W3WInvocableCalloutTest.cls-meta.xml | 2 +- .../default/classes/What3Words.cls-meta.xml | 2 +- .../main/default/classes/What3WordsTest.cls | 16 ++++----- .../classes/What3WordsTest.cls-meta.xml | 2 +- .../animalShelterSettingsEditor.js | 2 +- .../animalShelterSettingsEditor.js-meta.xml | 2 +- .../main/default/lwc/flowHLine/flowHLine.js | 2 +- .../lightningPrintView.js-meta.xml | 2 +- .../lightningVisualPicker.js | 2 +- .../lwc/microchipLookup/microchipLookup.html | 2 +- .../lwc/microchipLookup/microchipLookup.js | 6 ++-- .../microchipLookup.js-meta.xml | 2 +- .../lwc/recordAlerts/recordAlerts.html | 2 +- .../lwc/recordAlerts/recordAlerts.js-meta.xml | 2 +- .../default/lwc/recordImage/recordImage.html | 4 +-- .../default/lwc/recordImage/recordImage.js | 12 +++---- .../lwc/recordImage/recordImage.js-meta.xml | 2 +- .../main/default/pages/AnimalCageCard.page | 13 ++++---- .../pages/AnimalCageCard.page-meta.xml | 2 +- 61 files changed, 154 insertions(+), 145 deletions(-) diff --git a/.gitignore b/.gitignore index 9e5f54b8..b3bbc688 100644 --- a/.gitignore +++ b/.gitignore @@ -26,3 +26,4 @@ robot/animal_shelter_starter/results/ .DS_Store test_results.* +/IlluminatedCloud/ diff --git a/force-app/main/default/classes/AlertBannerController.cls b/force-app/main/default/classes/AlertBannerController.cls index 51531711..f906f9f5 100644 --- a/force-app/main/default/classes/AlertBannerController.cls +++ b/force-app/main/default/classes/AlertBannerController.cls @@ -26,7 +26,7 @@ public with sharing class AlertBannerController { return null; } - if(Schema.sObjectType.animalshelters__Animal_Alert__c.isAccessible() && Schema.sObjectType.animalshelters__Animal_Alert__c.fields.animalshelters__Alert_Message__c.isAccessible() && Schema.sObjectType.animalshelters__Animal_Alert__c.fields.animalshelters__Start_Date_Time__c.isAccessible() && Schema.sObjectType.animalshelters__Animal_Alert__c.fields.animalshelters__End_Date_Time__c.isAccessible()){ + if(Schema.SObjectType.animalshelters__Animal_Alert__c.isAccessible() && Schema.SObjectType.animalshelters__Animal_Alert__c.fields.animalshelters__Alert_Message__c.isAccessible() && Schema.SObjectType.animalshelters__Animal_Alert__c.fields.animalshelters__Start_Date_Time__c.isAccessible() && Schema.SObjectType.animalshelters__Animal_Alert__c.fields.animalshelters__End_Date_Time__c.isAccessible()){ List AlertList = [SELECT Id, animalshelters__Alert_Message__c,animalshelters__Start_Date_Time__c FROM animalshelters__Animal_Alert__c WHERE animalshelters__Animal__c = :parentId AND animalshelters__Start_Date_Time__c <= TODAY AND (animalshelters__End_Date_Time__c >= TODAY OR animalshelters__End_Date_Time__c = NULL) WITH SECURITY_ENFORCED LIMIT 20]; return AlertList; diff --git a/force-app/main/default/classes/AlertBannerController.cls-meta.xml b/force-app/main/default/classes/AlertBannerController.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/AlertBannerController.cls-meta.xml +++ b/force-app/main/default/classes/AlertBannerController.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/AlertBannerControllerTest.cls b/force-app/main/default/classes/AlertBannerControllerTest.cls index 15fdee7f..3f60234e 100644 --- a/force-app/main/default/classes/AlertBannerControllerTest.cls +++ b/force-app/main/default/classes/AlertBannerControllerTest.cls @@ -9,9 +9,10 @@ * Ver Date Author Modification * 1.0 4/30/2020 Stewart Anderson (Salesforce.org) Initial Version **/ -@isTest +@IsTest public class AlertBannerControllerTest { - static testMethod void testMethod1 () { + @IsTest + static void testMethod1 () { List AlertListTest = AlertBannerController.getRelatedAlertRecords('a003z00000rlhSbAAI'); List AlertListTest2 = AlertBannerController.getRelatedAlertRecords(null); } diff --git a/force-app/main/default/classes/AlertBannerControllerTest.cls-meta.xml b/force-app/main/default/classes/AlertBannerControllerTest.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/AlertBannerControllerTest.cls-meta.xml +++ b/force-app/main/default/classes/AlertBannerControllerTest.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/AnimalActionRLClass2.cls b/force-app/main/default/classes/AnimalActionRLClass2.cls index 5c8bab8d..ec22c328 100644 --- a/force-app/main/default/classes/AnimalActionRLClass2.cls +++ b/force-app/main/default/classes/AnimalActionRLClass2.cls @@ -18,15 +18,15 @@ public with sharing class AnimalActionRLClass2 { // System.debug('recId = ' + recId); // System.debug('rTypeName = ' + rTypeName); - if(Schema.sObjectType.animalshelters__Animal_Action__c.isAccessible() && Schema.sObjectType.animalshelters__Animal_Action__c.fields.name.isAccessible() && Schema.sObjectType.animalshelters__Animal_Action__c.fields.animalshelters__Action_Completed__c.isAccessible() && Schema.sObjectType.animalshelters__Animal_Action__c.fields.animalshelters__Date_Time_of_Action__c.isAccessible() && Schema.sObjectType.animalshelters__Animal_Action__c.fields.animalshelters__Description__c.isAccessible() && Schema.sObjectType.animalshelters__Animal_Action__c.fields.RecordTypeId.isAccessible() && Schema.sObjectType.animalshelters__Animal__c.isAccessible()){ + if(Schema.SObjectType.animalshelters__Animal_Action__c.isAccessible() && Schema.SObjectType.animalshelters__Animal_Action__c.fields.Name.isAccessible() && Schema.SObjectType.animalshelters__Animal_Action__c.fields.animalshelters__Action_Completed__c.isAccessible() && Schema.SObjectType.animalshelters__Animal_Action__c.fields.animalshelters__Date_Time_of_Action__c.isAccessible() && Schema.SObjectType.animalshelters__Animal_Action__c.fields.animalshelters__Description__c.isAccessible() && Schema.SObjectType.animalshelters__Animal_Action__c.fields.RecordTypeId.isAccessible() && Schema.SObjectType.animalshelters__Animal__c.isAccessible()){ List animalActions= new List(); - boolean blnFirstTimeRound = false; - for(RecordType rec : [SELECT Id FROM RecordType WHERE sObjectType = 'animalshelters__Animal_Action__c' and Name =:rTypeName]) + Boolean blnFirstTimeRound = false; + for(RecordType rec : [SELECT Id FROM RecordType WHERE SobjectType = 'animalshelters__Animal_Action__c' AND Name =:rTypeName]) { if (!blnFirstTimeRound){ List y = [SELECT Id, Name, animalshelters__Action_Completed__c, animalshelters__Date_Time_of_Action__c, animalshelters__Description__c FROM animalshelters__Animal_Action__c - WHERE animalshelters__Animal__c= :recId and RecordTypeId= :rec.Id WITH SECURITY_ENFORCED ]; + WHERE animalshelters__Animal__c= :recId AND RecordTypeId= :rec.Id WITH SECURITY_ENFORCED ]; for(animalshelters__Animal_Action__c z : y) { animalActions.add(z); diff --git a/force-app/main/default/classes/AnimalActionRLClass2.cls-meta.xml b/force-app/main/default/classes/AnimalActionRLClass2.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/AnimalActionRLClass2.cls-meta.xml +++ b/force-app/main/default/classes/AnimalActionRLClass2.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/AnimalActionRLClass2Test.cls b/force-app/main/default/classes/AnimalActionRLClass2Test.cls index 58f5f042..480775ea 100644 --- a/force-app/main/default/classes/AnimalActionRLClass2Test.cls +++ b/force-app/main/default/classes/AnimalActionRLClass2Test.cls @@ -9,7 +9,7 @@ * Ver Date Author Modification * 1.0 4/30/2020 Stewart Anderson (Salesforce.org) Initial Version **/ -@isTest +@IsTest public class AnimalActionRLClass2Test { @IsTest diff --git a/force-app/main/default/classes/AnimalActionRLClass2Test.cls-meta.xml b/force-app/main/default/classes/AnimalActionRLClass2Test.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/AnimalActionRLClass2Test.cls-meta.xml +++ b/force-app/main/default/classes/AnimalActionRLClass2Test.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/AnimalShelterFieldsetController.cls b/force-app/main/default/classes/AnimalShelterFieldsetController.cls index 3143da47..22511e3f 100644 --- a/force-app/main/default/classes/AnimalShelterFieldsetController.cls +++ b/force-app/main/default/classes/AnimalShelterFieldsetController.cls @@ -17,7 +17,7 @@ public with sharing class AnimalShelterFieldsetController { } } - @AuraEnabled(cacheable=true) + @AuraEnabled(Cacheable=true) public static List getFieldSet(String sObjectName, String fieldSetName) { List fieldSetMemberWrappers = new List(); @@ -48,7 +48,7 @@ public with sharing class AnimalShelterFieldsetController { return fieldSetMemberWrappers; } - @AuraEnabled(cacheable=true) + @AuraEnabled(Cacheable=true) public static Map> getBadgeFieldsData(String recordId, String sObjectName, List badgeFieldNames) { // Check Object and Field Security diff --git a/force-app/main/default/classes/AnimalShelterFieldsetControllerTest.cls b/force-app/main/default/classes/AnimalShelterFieldsetControllerTest.cls index 7f39cd1a..a0b1ca09 100644 --- a/force-app/main/default/classes/AnimalShelterFieldsetControllerTest.cls +++ b/force-app/main/default/classes/AnimalShelterFieldsetControllerTest.cls @@ -5,10 +5,10 @@ * @last modified on : 12-22-2023 * @last modified by : Stewart Anderson **/ -@isTest +@IsTest private class AnimalShelterFieldsetControllerTest { - @isTest static void testGetFieldSet() { + @IsTest static void testGetFieldSet() { // Setup test data // Since Schema and FieldSets cannot be created in test methods, // we'll assume there's an existing object and field set available. @@ -24,7 +24,7 @@ private class AnimalShelterFieldsetControllerTest { System.assertNotEquals(0, result.size(), 'The result should have elements'); } - @isTest static void testGetBadgeFieldsData() { + @IsTest static void testGetBadgeFieldsData() { // Setup test data // Create a record for the sObject you're testing against animalshelters__Animal__c testRecord = new animalshelters__Animal__c(animalshelters__Animal_Name__c='Test', animalshelters__Date_of_Arrival__c=Datetime.now()); diff --git a/force-app/main/default/classes/AnimalShelterFieldsetControllerTest.cls-meta.xml b/force-app/main/default/classes/AnimalShelterFieldsetControllerTest.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/AnimalShelterFieldsetControllerTest.cls-meta.xml +++ b/force-app/main/default/classes/AnimalShelterFieldsetControllerTest.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/AnimalShelterGetCustomSettings.cls b/force-app/main/default/classes/AnimalShelterGetCustomSettings.cls index be47b5d3..aceb72bf 100644 --- a/force-app/main/default/classes/AnimalShelterGetCustomSettings.cls +++ b/force-app/main/default/classes/AnimalShelterGetCustomSettings.cls @@ -7,9 +7,9 @@ **/ public with sharing class AnimalShelterGetCustomSettings { - @AuraEnabled(cacheable=true) + @AuraEnabled(Cacheable=true) public static animalshelters__Animal_Shelter_Settings__c getCustomSettings(){ - if (Schema.sObjectType.animalshelters__Animal_Shelter_Settings__c.isAccessible()) { + if (Schema.SObjectType.animalshelters__Animal_Shelter_Settings__c.isAccessible()) { return animalshelters__Animal_Shelter_Settings__c.getOrgDefaults(); } else { throw new AuraHandledException('Access Issue: There was an attempt to access Animal Shelter Starter Settings by a user without access.'); @@ -19,7 +19,7 @@ public with sharing class AnimalShelterGetCustomSettings { @AuraEnabled public static void saveCustomSetting(animalshelters__Animal_Shelter_Settings__c customSetting) { - if (Schema.sObjectType.animalshelters__Animal_Shelter_Settings__c.isUpdateable()) { + if (Schema.SObjectType.animalshelters__Animal_Shelter_Settings__c.isUpdateable()) { update customSetting; } else { throw new AuraHandledException('Access Issue: There was an attempt to update Animal Shelter Starter Settings by a user without access.'); diff --git a/force-app/main/default/classes/AnimalShelterGetCustomSettings.cls-meta.xml b/force-app/main/default/classes/AnimalShelterGetCustomSettings.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/AnimalShelterGetCustomSettings.cls-meta.xml +++ b/force-app/main/default/classes/AnimalShelterGetCustomSettings.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/AnimalShelterGetCustomSettingsTest.cls b/force-app/main/default/classes/AnimalShelterGetCustomSettingsTest.cls index c2c799d6..d4ed71ff 100644 --- a/force-app/main/default/classes/AnimalShelterGetCustomSettingsTest.cls +++ b/force-app/main/default/classes/AnimalShelterGetCustomSettingsTest.cls @@ -11,8 +11,8 @@ private class AnimalShelterGetCustomSettingsTest { @IsTest static void testGetCustomSetting() { // Create a new custom setting record animalshelters__Animal_Shelter_Settings__c setting = new animalshelters__Animal_Shelter_Settings__c(); - setting.animalshelters__Breeds_Migration_Complete__c = True; - setting.animalshelters__Default_Animal_Name__c = False; + setting.animalshelters__Breeds_Migration_Complete__c = true; + setting.animalshelters__Default_Animal_Name__c = false; setting.animalshelters__Default_Animal_Name_Prefix__c = 'pre'; setting.animalshelters__microchip_api_Token__c = 'TestValue'; insert setting; @@ -25,8 +25,8 @@ private class AnimalShelterGetCustomSettingsTest { @IsTest static void testSaveCustomSetting() { // Create a new custom setting record animalshelters__Animal_Shelter_Settings__c setting = new animalshelters__Animal_Shelter_Settings__c(); - setting.animalshelters__Breeds_Migration_Complete__c = True; - setting.animalshelters__Default_Animal_Name__c = False; + setting.animalshelters__Breeds_Migration_Complete__c = true; + setting.animalshelters__Default_Animal_Name__c = false; setting.animalshelters__Default_Animal_Name_Prefix__c = 'pre'; setting.animalshelters__microchip_api_Token__c = 'TestValueNew'; insert setting; diff --git a/force-app/main/default/classes/AnimalShelterGetCustomSettingsTest.cls-meta.xml b/force-app/main/default/classes/AnimalShelterGetCustomSettingsTest.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/AnimalShelterGetCustomSettingsTest.cls-meta.xml +++ b/force-app/main/default/classes/AnimalShelterGetCustomSettingsTest.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/FSCAnimalCloneDatatableController.cls-meta.xml b/force-app/main/default/classes/FSCAnimalCloneDatatableController.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/FSCAnimalCloneDatatableController.cls-meta.xml +++ b/force-app/main/default/classes/FSCAnimalCloneDatatableController.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/FSCAnimalCloneDatatableControllerTest.cls b/force-app/main/default/classes/FSCAnimalCloneDatatableControllerTest.cls index 53b5c332..2e3d30cc 100644 --- a/force-app/main/default/classes/FSCAnimalCloneDatatableControllerTest.cls +++ b/force-app/main/default/classes/FSCAnimalCloneDatatableControllerTest.cls @@ -1,14 +1,14 @@ -@isTest +@IsTest public class FSCAnimalCloneDatatableControllerTest { @TestSetup static void setupTestData(){ - animalshelters__Animal__c testAnimal = new animalshelters__Animal__c(animalshelters__Animal_Name__c = 'Tandy', animalshelters__Type__c = 'Rabbit', animalshelters__Date_of_Arrival__c = Date.today(), animalshelters__IsCloned__c = True); - Insert testAnimal; + animalshelters__Animal__c testAnimal = new animalshelters__Animal__c(animalshelters__Animal_Name__c = 'Tandy', animalshelters__Type__c = 'Rabbit', animalshelters__Date_of_Arrival__c = Date.today(), animalshelters__IsCloned__c = true); + insert testAnimal; } - @isTest static void testReadRecord(){ + @IsTest static void testReadRecord(){ List tstRecord = new List(); tstRecord = FSCAnimalCloneDatatableController.getClonedAnimals(); @@ -16,10 +16,10 @@ public class FSCAnimalCloneDatatableControllerTest { } - @isTest static void testUpdateRecord(){ + @IsTest static void testUpdateRecord(){ List tstUpdate = new List(); - List updateAnimal = [SELECT animalshelters__Animal_Name__c, animalshelters__Type__c, animalshelters__Date_of_Arrival__c FROM animalshelters__Animal__c WHERE animalshelters__IsCloned__c = True]; + List updateAnimal = [SELECT animalshelters__Animal_Name__c, animalshelters__Type__c, animalshelters__Date_of_Arrival__c FROM animalshelters__Animal__c WHERE animalshelters__IsCloned__c = TRUE]; updateAnimal.get(0).animalshelters__Animal_Name__c = 'Tommy'; tstUpdate = FSCAnimalCloneDatatableController.updateClonedRecords(updateAnimal); System.assertEquals(tstUpdate.get(0).animalshelters__Animal_Name__c, 'Tommy','Animal name !="Tommy"'); diff --git a/force-app/main/default/classes/FSCAnimalCloneDatatableControllerTest.cls-meta.xml b/force-app/main/default/classes/FSCAnimalCloneDatatableControllerTest.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/FSCAnimalCloneDatatableControllerTest.cls-meta.xml +++ b/force-app/main/default/classes/FSCAnimalCloneDatatableControllerTest.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/FSC_FileUploadPreviewController.cls b/force-app/main/default/classes/FSC_FileUploadPreviewController.cls index 09424151..630eefb3 100644 --- a/force-app/main/default/classes/FSC_FileUploadPreviewController.cls +++ b/force-app/main/default/classes/FSC_FileUploadPreviewController.cls @@ -33,7 +33,7 @@ public with sharing class FSC_FileUploadPreviewController { @AuraEnabled public static void deleteFile(String contentDocumentId){ - if (ContentDocument.sObjectType.getDescribe().isDeletable()){ + if (ContentDocument.SObjectType.getDescribe().isDeletable()){ delete [SELECT Id FROM ContentDocument WHERE Id = :contentDocumentId diff --git a/force-app/main/default/classes/FSC_FileUploadPreviewController.cls-meta.xml b/force-app/main/default/classes/FSC_FileUploadPreviewController.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/FSC_FileUploadPreviewController.cls-meta.xml +++ b/force-app/main/default/classes/FSC_FileUploadPreviewController.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/FSC_FileUploadPreviewControllerTest.cls b/force-app/main/default/classes/FSC_FileUploadPreviewControllerTest.cls index ff3c3b58..322f58bc 100644 --- a/force-app/main/default/classes/FSC_FileUploadPreviewControllerTest.cls +++ b/force-app/main/default/classes/FSC_FileUploadPreviewControllerTest.cls @@ -34,7 +34,7 @@ public class FSC_FileUploadPreviewControllerTest { } - @isTest static void testReadDocument(){ + @IsTest static void testReadDocument(){ List accList = [SELECT Id FROM Account WHERE Name = 'ASS Test Account' LIMIT 1]; for(Account acc : accList){ @@ -44,7 +44,7 @@ public class FSC_FileUploadPreviewControllerTest { } } - @isTest static void testDeleteDocument(){ + @IsTest static void testDeleteDocument(){ List cdList = [SELECT Id FROM ContentDocument WHERE Title = 'ASS Test File' LIMIT 1]; for(ContentDocument cd : cdList){ diff --git a/force-app/main/default/classes/FSC_FileUploadPreviewControllerTest.cls-meta.xml b/force-app/main/default/classes/FSC_FileUploadPreviewControllerTest.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/FSC_FileUploadPreviewControllerTest.cls-meta.xml +++ b/force-app/main/default/classes/FSC_FileUploadPreviewControllerTest.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/GetRandomNumber.cls b/force-app/main/default/classes/GetRandomNumber.cls index e338acfa..4eb6b2c1 100644 --- a/force-app/main/default/classes/GetRandomNumber.cls +++ b/force-app/main/default/classes/GetRandomNumber.cls @@ -20,7 +20,7 @@ global with sharing class GetRandomNumber { Results curResult = new Results(); curResult.randomNumber = generateRandomFromRange(requests[0].startNumber, requests[0].endNumber); - List resultsList = new List(); + List resultsList = new List(); resultsList.add(curResult); return resultsList; } @@ -37,41 +37,44 @@ global with sharing class GetRandomNumber { global static Double generateRandomFromRange(Integer startNum, Integer endNum) { - if(startNum == 0 && endNum == 1) + if (startNum == 0 && endNum == 1) { return Math.random(); + } Integer returnValue; //Logic- first we will generate random boolean value which will decide if we want to //add the random number from startNum or will subtract random number from endNum - Integer randomNumber = Integer.valueof((math.random() * 10)); - boolean addSubFlag= math.mod(randomNumber,2) == 0 ? true : false; + Integer randomNumber = Integer.valueOf((Math.random() * 10)); + Boolean addSubFlag= Math.mod(randomNumber,2) == 0 ? true : false; - integer diffInRange = endNum-startNum; + Integer diffInRange = endNum-startNum; //Now find random number staring from 0 to diffInRange Integer randomNum = Math.mod(Math.round(Math.random()*diffInRange+1),diffInRange); //If addSubFlag is true, we will add random number generated between 0 and diffInRange from start number //else we will subtract random number from end number if(addSubFlag){ - if(diffInRange > 1) - returnValue =startNum + randomNum; - else - returnValue =startNum; + if (diffInRange > 1) { + returnValue = startNum + randomNum; + } else { + returnValue = startNum; + } }else{ - if(diffInRange > 1) - returnValue = endNum - randomNum; - else - returnValue =endNum; + if (diffInRange > 1) { + returnValue = endNum - randomNum; + } else { + returnValue = endNum; + } } return returnValue; } global class Requests { - @InvocableVariable(required=true) + @InvocableVariable(Required=true) global Integer startNumber; - @InvocableVariable(required=true) + @InvocableVariable(Required=true) global Integer endNumber; } diff --git a/force-app/main/default/classes/GetRandomNumber.cls-meta.xml b/force-app/main/default/classes/GetRandomNumber.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/GetRandomNumber.cls-meta.xml +++ b/force-app/main/default/classes/GetRandomNumber.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/GetRandomNumberTest.cls b/force-app/main/default/classes/GetRandomNumberTest.cls index a1833fbc..4ac6e9a6 100644 --- a/force-app/main/default/classes/GetRandomNumberTest.cls +++ b/force-app/main/default/classes/GetRandomNumberTest.cls @@ -1,7 +1,7 @@ -@isTest +@IsTest global with sharing class GetRandomNumberTest { - @isTest + @IsTest public static void numberReturnedIsInRange() { Integer startNum = 0; Integer endNum =1; @@ -23,7 +23,7 @@ global with sharing class GetRandomNumberTest { System.assertEquals(true, resultNum <= endNum); } - @isTest + @IsTest public static void numberZeroToOneGeneratedIsInRange() { Integer startNum = 0; Integer endNum =1; @@ -36,7 +36,7 @@ global with sharing class GetRandomNumberTest { System.assertEquals(true, resultNum <= endNum); } - @isTest + @IsTest public static void numberAboveOneGeneratedIsInRange() { Integer startNum = 5; Integer endNum =7; diff --git a/force-app/main/default/classes/GetRandomNumberTest.cls-meta.xml b/force-app/main/default/classes/GetRandomNumberTest.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/GetRandomNumberTest.cls-meta.xml +++ b/force-app/main/default/classes/GetRandomNumberTest.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/LocationController.cls b/force-app/main/default/classes/LocationController.cls index 20a9847f..a893b20d 100644 --- a/force-app/main/default/classes/LocationController.cls +++ b/force-app/main/default/classes/LocationController.cls @@ -42,12 +42,12 @@ public with sharing class LocationController { List loc = new List(); for(sObject locs :myData){ GeoLocation geoInfo = new GeoLocation(); - geoInfo.Latitude = String.ValueOf(locs.get(varLat)); - geoInfo.Longitude = String.ValueOf(locs.get(varLong)); + geoInfo.Latitude = String.valueOf(locs.get(varLat)); + geoInfo.Longitude = String.valueOf(locs.get(varLong)); Location locDetail = new Location(); locDetail.icon = 'utility:animal_and_nature'; - locDetail.title = String.ValueOf(locs.get(varName)); - locDetail.description = locs.get(varDescText) + ' - ' + fieldLabel + ': ' + String.ValueOf(locs.get(varDescDate)); + locDetail.title = String.valueOf(locs.get(varName)); + locDetail.description = locs.get(varDescText) + ' - ' + fieldLabel + ': ' + String.valueOf(locs.get(varDescDate)); locDetail.location = geoInfo; loc.add(locDetail); diff --git a/force-app/main/default/classes/LocationController.cls-meta.xml b/force-app/main/default/classes/LocationController.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/LocationController.cls-meta.xml +++ b/force-app/main/default/classes/LocationController.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/LocationControllerTest.cls b/force-app/main/default/classes/LocationControllerTest.cls index b67ad1e7..b696b7a5 100644 --- a/force-app/main/default/classes/LocationControllerTest.cls +++ b/force-app/main/default/classes/LocationControllerTest.cls @@ -1,13 +1,14 @@ -@isTest +@IsTest public class LocationControllerTest { @TestSetup static void setupTestData(){ - animalshelters__Animal__c testAnimal = new animalshelters__Animal__c(animalshelters__Animal_Name__c = 'Tandy', animalshelters__Geolocation__latitude__s = 50.826425, animalshelters__Geolocation__longitude__s = -0.403983, animalshelters__Type__c = 'Rabbit', animalshelters__Date_of_Arrival__c = Date.today()); - Insert testAnimal; + animalshelters__Animal__c testAnimal = new animalshelters__Animal__c(animalshelters__Animal_Name__c = 'Tandy', animalshelters__Geolocation__Latitude__s = 50.826425, animalshelters__Geolocation__Longitude__s = -0.403983, animalshelters__Type__c = 'Rabbit', animalshelters__Date_of_Arrival__c = Date.today()); + insert testAnimal; } - static testMethod void testLocation() { + @IsTest + static void testLocation() { String tstObj = 'animalshelters__Animal__c'; String tstName = 'animalshelters__Animal_Name__c'; @@ -16,12 +17,12 @@ public class LocationControllerTest { String tstText = 'animalshelters__Type__c'; String tstDate = 'animalshelters__Date_of_Arrival__c'; - List animal = [SELECT animalshelters__Animal_Name__c, animalshelters__Geolocation__latitude__s, animalshelters__Geolocation__longitude__s, animalshelters__Type__c, animalshelters__Date_of_Arrival__c FROM animalshelters__Animal__c]; + List animal = [SELECT animalshelters__Animal_Name__c, animalshelters__Geolocation__Latitude__s, animalshelters__Geolocation__Longitude__s, animalshelters__Type__c, animalshelters__Date_of_Arrival__c FROM animalshelters__Animal__c]; System.assertEquals(true,animal.size()>0,'Read Animal Record Failed'); List tstLoc = new List(); tstLoc = LocationController.getLocation(tstObj, tstLat, tstLong, tstName, tstText, tstDate); - System.assertEquals(true,String.ValueOf(tstLoc).contains('title=Tandy'),'Location Data Incorrect'); + System.assertEquals(true,String.valueOf(tstLoc).contains('title=Tandy'),'Location Data Incorrect'); } } \ No newline at end of file diff --git a/force-app/main/default/classes/LocationControllerTest.cls-meta.xml b/force-app/main/default/classes/LocationControllerTest.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/LocationControllerTest.cls-meta.xml +++ b/force-app/main/default/classes/LocationControllerTest.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/MockW3WResponseGenerator.cls b/force-app/main/default/classes/MockW3WResponseGenerator.cls index 49dcbaa8..1ee37a3d 100644 --- a/force-app/main/default/classes/MockW3WResponseGenerator.cls +++ b/force-app/main/default/classes/MockW3WResponseGenerator.cls @@ -1,10 +1,10 @@ global class MockW3WResponseGenerator implements HttpCalloutMock { - global HTTPResponse respond(HTTPRequest req) { + global HttpResponse respond(HttpRequest req) { // Create a fake response HttpResponse res = new HttpResponse(); res.setHeader('Content-Type', 'application/json'); - string result = '{ "country": "GB", "square": { "southwest": { "lng": -0.403987, "lat": 50.826272 }, "northeast": { "lng": -0.403945, "lat": 50.826299 } }, "nearestPlace": "Goring-by-Sea, West Sussex", "coordinates": { "lng": -0.403966, "lat": 50.826286 }, "words": "whips.vanish.store", "language": "en", "map": "https://w3w.co/whips.vanish.store" }'; + String result = '{ "country": "GB", "square": { "southwest": { "lng": -0.403987, "lat": 50.826272 }, "northeast": { "lng": -0.403945, "lat": 50.826299 } }, "nearestPlace": "Goring-by-Sea, West Sussex", "coordinates": { "lng": -0.403966, "lat": 50.826286 }, "words": "whips.vanish.store", "language": "en", "map": "https://w3w.co/whips.vanish.store" }'; res.setBody(result); res.setStatusCode(200); return res; diff --git a/force-app/main/default/classes/MockW3WResponseGenerator.cls-meta.xml b/force-app/main/default/classes/MockW3WResponseGenerator.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/MockW3WResponseGenerator.cls-meta.xml +++ b/force-app/main/default/classes/MockW3WResponseGenerator.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/MockW3WResponseGeneratorTest.cls b/force-app/main/default/classes/MockW3WResponseGeneratorTest.cls index 5965c786..8440a115 100644 --- a/force-app/main/default/classes/MockW3WResponseGeneratorTest.cls +++ b/force-app/main/default/classes/MockW3WResponseGeneratorTest.cls @@ -1,7 +1,7 @@ -@isTest +@IsTest private class MockW3WResponseGeneratorTest { - @isTest + @IsTest static void testRespond() { // Create a mock request HttpRequest req = new HttpRequest(); diff --git a/force-app/main/default/classes/MockW3WResponseGeneratorTest.cls-meta.xml b/force-app/main/default/classes/MockW3WResponseGeneratorTest.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/MockW3WResponseGeneratorTest.cls-meta.xml +++ b/force-app/main/default/classes/MockW3WResponseGeneratorTest.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/ProfilePictureController.cls b/force-app/main/default/classes/ProfilePictureController.cls index f0f0533f..39327764 100644 --- a/force-app/main/default/classes/ProfilePictureController.cls +++ b/force-app/main/default/classes/ProfilePictureController.cls @@ -2,9 +2,9 @@ public with sharing class ProfilePictureController { @AuraEnabled public static Attachment getProfilePicture(Id parentId) { - if (Schema.sObjectType.Attachment.isAccessible()) { + if (Schema.SObjectType.Attachment.isAccessible()) { return [SELECT Id, Name, LastModifiedDate, ContentType FROM Attachment - WHERE parentid=:ParentId AND ContentType IN ('image/png', 'image/jpeg', 'image/gif') + WHERE ParentId=:parentId AND ContentType IN ('image/png', 'image/jpeg', 'image/gif') ORDER BY LastModifiedDate DESC LIMIT 1]; } System.debug('User does not have access to view Attachments. Please review access.'); @@ -13,14 +13,14 @@ public with sharing class ProfilePictureController { @AuraEnabled public static Id saveAttachment(Id parentId, String fileName, String base64Data, String contentType) { - if (Schema.sObjectType.Attachment.isCreateable() && Schema.sObjectType.Attachment.fields.parentId.isAccessible() && Schema.sObjectType.Attachment.fields.name.isAccessible() && Schema.sObjectType.Attachment.fields.contentType.isAccessible()) { + if (Schema.SObjectType.Attachment.isCreateable() && Schema.SObjectType.Attachment.fields.ParentId.isAccessible() && Schema.SObjectType.Attachment.fields.Name.isAccessible() && Schema.SObjectType.Attachment.fields.ContentType.isAccessible()) { Attachment attachment = new Attachment(); - attachment.parentId = parentId; - attachment.body = EncodingUtil.base64Decode(base64Data); - attachment.name = fileName; - attachment.contentType = contentType; + attachment.ParentId = parentId; + attachment.Body = EncodingUtil.base64Decode(base64Data); + attachment.Name = fileName; + attachment.ContentType = contentType; insert attachment; - return attachment.id; + return attachment.Id; } System.debug('User does not have access to create Attachments. Please review access.'); return null; diff --git a/force-app/main/default/classes/ProfilePictureController.cls-meta.xml b/force-app/main/default/classes/ProfilePictureController.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/ProfilePictureController.cls-meta.xml +++ b/force-app/main/default/classes/ProfilePictureController.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/ProfilePictureControllerTest.cls b/force-app/main/default/classes/ProfilePictureControllerTest.cls index 2705be86..257b00fc 100644 --- a/force-app/main/default/classes/ProfilePictureControllerTest.cls +++ b/force-app/main/default/classes/ProfilePictureControllerTest.cls @@ -1,11 +1,12 @@ -@isTest +@IsTest public class ProfilePictureControllerTest { - static testMethod void testMethod1 () { - animalshelters__Animal__c TestAnimal = new animalshelters__Animal__c (animalshelters__Animal_Name__c='rex', animalshelters__Date_of_Arrival__c = date.today(), animalshelters__Type__c = 'Dog'); + @IsTest + static void testMethod1 () { + animalshelters__Animal__c TestAnimal = new animalshelters__Animal__c (animalshelters__Animal_Name__c='rex', animalshelters__Date_of_Arrival__c = Date.today(), animalshelters__Type__c = 'Dog'); insert TestAnimal; - ProfilePictureController.saveAttachment(TestAnimal.id, 'Test File', '', 'image/jpeg'); + ProfilePictureController.saveAttachment(TestAnimal.Id, 'Test File', '', 'image/jpeg'); - ProfilePictureController.getProfilePicture(TestAnimal.id); + ProfilePictureController.getProfilePicture(TestAnimal.Id); } } \ No newline at end of file diff --git a/force-app/main/default/classes/ProfilePictureControllerTest.cls-meta.xml b/force-app/main/default/classes/ProfilePictureControllerTest.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/ProfilePictureControllerTest.cls-meta.xml +++ b/force-app/main/default/classes/ProfilePictureControllerTest.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/W3WInvocableCallout.cls b/force-app/main/default/classes/W3WInvocableCallout.cls index 99f0cbbc..d6ca43a2 100644 --- a/force-app/main/default/classes/W3WInvocableCallout.cls +++ b/force-app/main/default/classes/W3WInvocableCallout.cls @@ -11,7 +11,7 @@ **/ public with sharing class W3WInvocableCallout { - @InvocableMethod(label='Get W3W Coordinates' description='Returns the Latitude and Longitude of the W3W provided' category='Animal') + @InvocableMethod(Label='Get W3W Coordinates' Description='Returns the Latitude and Longitude of the W3W provided' Category='Animal') public static List getW3WCoordinates(List animals) { for (animalshelters__Animal__c theAnimal : animals) { @@ -20,14 +20,14 @@ public with sharing class W3WInvocableCallout { return null; } - @future(callout=true) + @Future(Callout=true) public static void updateAnimal(String theAnimalStr ) { animalshelters__Animal__c theAnimal = (animalshelters__Animal__c)JSON.deserialize(theAnimalStr, animalshelters__Animal__c.class); //Add key as a Custom setting animalshelters__Animal_Shelter_Settings__c apikey = animalshelters__Animal_Shelter_Settings__c.getOrgDefaults(); - string w3wkey = apikey.animalshelters__What3Words_API_Key__c; + String w3wkey = apikey.animalshelters__What3Words_API_Key__c; Http http = new Http(); HttpRequest request = new HttpRequest(); @@ -38,11 +38,11 @@ public with sharing class W3WInvocableCallout { request.setMethod('GET'); HttpResponse response = http.send(request); // If the request is successful, parse the JSON response. - if (response.getStatusCode() == 200 && Schema.sObjectType.animalshelters__Animal__c.isAccessible() && Schema.sObjectType.animalshelters__Animal__c.fields.animalshelters__Geolocation__c.isAccessible()){ + if (response.getStatusCode() == 200 && Schema.SObjectType.animalshelters__Animal__c.isAccessible() && Schema.SObjectType.animalshelters__Animal__c.fields.animalshelters__Geolocation__c.isAccessible()){ // Deserialize the JSON string into collections of primitive data types. What3Words theResult = What3Words.parse(response.getBody()); - theAnimal.animalshelters__Geolocation__latitude__s = theResult.coordinates.lat; - theAnimal.animalshelters__Geolocation__longitude__s = theResult.coordinates.lng; + theAnimal.animalshelters__Geolocation__Latitude__s = theResult.coordinates.lat; + theAnimal.animalshelters__Geolocation__Longitude__s = theResult.coordinates.lng; update theAnimal; } } diff --git a/force-app/main/default/classes/W3WInvocableCallout.cls-meta.xml b/force-app/main/default/classes/W3WInvocableCallout.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/W3WInvocableCallout.cls-meta.xml +++ b/force-app/main/default/classes/W3WInvocableCallout.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/W3WInvocableCalloutTest.cls b/force-app/main/default/classes/W3WInvocableCalloutTest.cls index 7202def8..409eb0bb 100644 --- a/force-app/main/default/classes/W3WInvocableCalloutTest.cls +++ b/force-app/main/default/classes/W3WInvocableCalloutTest.cls @@ -5,20 +5,21 @@ * @last modified on : 10-17-2023 * @last modified by : Stewart Anderson **/ -@isTest +@IsTest private class W3WInvocableCalloutTest { - @isTest static void testCallout() { + @IsTest + static void testCallout() { Test.setMock(HttpCalloutMock.class, new MockW3WResponseGenerator()); - animalshelters__Animal__c theAnimal = new animalshelters__Animal__c(animalshelters__Date_of_Arrival__c = Date.Today(), animalshelters__what3words__c = 'whips.vanish.store'); + animalshelters__Animal__c theAnimal = new animalshelters__Animal__c(animalshelters__Date_of_Arrival__c = Date.today(), animalshelters__what3words__c = 'whips.vanish.store'); insert theAnimal; List animals = new List(); animals.add(theAnimal); - test.startTest(); + Test.startTest(); W3WInvocableCallout.getW3WCoordinates(animals); - test.stopTest(); + Test.stopTest(); } } \ No newline at end of file diff --git a/force-app/main/default/classes/W3WInvocableCalloutTest.cls-meta.xml b/force-app/main/default/classes/W3WInvocableCalloutTest.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/W3WInvocableCalloutTest.cls-meta.xml +++ b/force-app/main/default/classes/W3WInvocableCalloutTest.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/What3Words.cls-meta.xml b/force-app/main/default/classes/What3Words.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/What3Words.cls-meta.xml +++ b/force-app/main/default/classes/What3Words.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/classes/What3WordsTest.cls b/force-app/main/default/classes/What3WordsTest.cls index 2eef9bab..b73eec72 100644 --- a/force-app/main/default/classes/What3WordsTest.cls +++ b/force-app/main/default/classes/What3WordsTest.cls @@ -5,10 +5,10 @@ * @last modified on : 10-17-2023 * @last modified by : ChangeMeIn@UserSettingsUnder.SFDoc **/ -@isTest +@IsTest private class What3WordsTest { - @isTest + @IsTest static void testParse_ValidJson() { String json = '{"country":"United States","square":{"southwest":{"lng":-77.036604,"lat":38.897626},"northeast":{"lng":-77.036505,"lat":38.897725}},"nearestPlace":"White House, Washington D.C.","coordinates":{"lng":-77.036572,"lat":38.897675},"words":"filled.count.soap","language":"en","map":"https://w3w.co/filled.count.soap"}'; @@ -30,7 +30,7 @@ private class What3WordsTest { System.assertEquals(38.897675, coordinates.lat); } - @isTest + @IsTest static void testParse_NullValues() { String json = '{"country":null,"square":null,"nearestPlace":null,"coordinates":null,"words":null,"language":null,"map":null}'; @@ -45,7 +45,7 @@ private class What3WordsTest { System.assertEquals(null, w3w.coordinates); } - @isTest + @IsTest static void testConsumeObject_StartObject() { String json = '{ "obj": { "prop": "value" } }'; @@ -59,7 +59,7 @@ private class What3WordsTest { System.assertEquals(System.JSONToken.END_OBJECT, parser.getCurrentToken()); } - @isTest + @IsTest static void testConsumeObject_StartArray() { String json = '{ "arr": [ "value" ] }'; @@ -73,7 +73,7 @@ private class What3WordsTest { System.assertEquals(System.JSONToken.END_ARRAY, parser.getCurrentToken()); } - @isTest + @IsTest static void testConsumeObject_MultipleObjects() { String json = '{ "obj1": { "prop1": "value1" }, "obj2": { "prop2": "value2" } }'; @@ -90,7 +90,7 @@ private class What3WordsTest { System.assertEquals(System.JSONToken.END_OBJECT, parser.getCurrentToken()); } - @isTest + @IsTest static void testSquare_ValidJson() { String json = '{ "southwest": { "lng": -77.036604, "lat": 38.897626 }, "northeast": { "lng": -77.036505, "lat": 38.897725 } }'; @@ -102,7 +102,7 @@ private class What3WordsTest { System.assertEquals(38.897725, square.northeast.lat); } - @isTest + @IsTest static void testSouthwest_ValidJson() { String json = '{ "lng": -77.036572, "lat": 38.897675 }'; diff --git a/force-app/main/default/classes/What3WordsTest.cls-meta.xml b/force-app/main/default/classes/What3WordsTest.cls-meta.xml index b1a915c9..f5e18fd1 100644 --- a/force-app/main/default/classes/What3WordsTest.cls-meta.xml +++ b/force-app/main/default/classes/What3WordsTest.cls-meta.xml @@ -1,5 +1,5 @@ - 59.0 + 60.0 Active diff --git a/force-app/main/default/lwc/animalShelterSettingsEditor/animalShelterSettingsEditor.js b/force-app/main/default/lwc/animalShelterSettingsEditor/animalShelterSettingsEditor.js index 9e6ccbf3..05baf92b 100644 --- a/force-app/main/default/lwc/animalShelterSettingsEditor/animalShelterSettingsEditor.js +++ b/force-app/main/default/lwc/animalShelterSettingsEditor/animalShelterSettingsEditor.js @@ -1,5 +1,5 @@ import { LightningElement, wire, track } from 'lwc'; -import { getRecord, updateRecord } from 'lightning/uiRecordApi'; +import { updateRecord } from 'lightning/uiRecordApi'; import getCustomSetting from '@salesforce/apex/AnimalShelterGetCustomSettings.getCustomSettings'; import createDefaultSettings from '@salesforce/apex/AnimalShelterGetCustomSettings.createDefaultSettings'; diff --git a/force-app/main/default/lwc/animalShelterSettingsEditor/animalShelterSettingsEditor.js-meta.xml b/force-app/main/default/lwc/animalShelterSettingsEditor/animalShelterSettingsEditor.js-meta.xml index 1b08a41a..9eb3efcf 100644 --- a/force-app/main/default/lwc/animalShelterSettingsEditor/animalShelterSettingsEditor.js-meta.xml +++ b/force-app/main/default/lwc/animalShelterSettingsEditor/animalShelterSettingsEditor.js-meta.xml @@ -1,6 +1,6 @@ - 59.0 + 60.0 true Animal Shelter Settings Editor Allows the user to easily change custom settings for Animal Shelter Starter diff --git a/force-app/main/default/lwc/flowHLine/flowHLine.js b/force-app/main/default/lwc/flowHLine/flowHLine.js index 5bcfe4a2..0f958972 100644 --- a/force-app/main/default/lwc/flowHLine/flowHLine.js +++ b/force-app/main/default/lwc/flowHLine/flowHLine.js @@ -33,6 +33,6 @@ export default class FlowHLine extends LightningElement { } get displayVCard(){ - return (this.vCard === true) ? true : false; + return (this.vCard === true); } } \ No newline at end of file diff --git a/force-app/main/default/lwc/lightningPrintView/lightningPrintView.js-meta.xml b/force-app/main/default/lwc/lightningPrintView/lightningPrintView.js-meta.xml index bd0e881f..e6168285 100644 --- a/force-app/main/default/lwc/lightningPrintView/lightningPrintView.js-meta.xml +++ b/force-app/main/default/lwc/lightningPrintView/lightningPrintView.js-meta.xml @@ -1,6 +1,6 @@ - 59.0 + 60.0 true Lightning Print View Reusable Print View Component which uses related field sets to print fields. diff --git a/force-app/main/default/lwc/lightningVisualPicker/lightningVisualPicker.js b/force-app/main/default/lwc/lightningVisualPicker/lightningVisualPicker.js index 928af324..8c84b00f 100644 --- a/force-app/main/default/lwc/lightningVisualPicker/lightningVisualPicker.js +++ b/force-app/main/default/lwc/lightningVisualPicker/lightningVisualPicker.js @@ -61,7 +61,7 @@ export default class LightningVisualPicker extends LightningElement { } if (this.options.length > 0 - && this.options.length != this.items.length) { + && this.options.length !== this.items.length) { let iterator = 0; let items = []; this.options.forEach(option => { diff --git a/force-app/main/default/lwc/microchipLookup/microchipLookup.html b/force-app/main/default/lwc/microchipLookup/microchipLookup.html index 787f77c3..a2993ead 100644 --- a/force-app/main/default/lwc/microchipLookup/microchipLookup.html +++ b/force-app/main/default/lwc/microchipLookup/microchipLookup.html @@ -57,7 +57,7 @@

Click Refresh Results to see