You need to sign in to do that
Don't have an account?

APEX Code Coverage Test Class
I am having trouble with creating a test class for a trigger I just created. This is the first trigger that I have created and it functions perfectly however, I currently have 0% code coverage. I have been reading the force.com Developers Guide and SDFC99.com to try to obtain some knowledge on where to even start with this test class but I am not even sure what to test.
Below is the apex trigger I have created.
The failure message that I am getting right now is below:

Thank you for any assistance that is provided.
Below is the apex trigger I have created.
trigger UpdateFieldValues on Case (after insert) { Id accessory360Id = [SELECT Id FROM Accessory__c WHERE Name='197 - 360μm FiberFlex™ Fiber' Limit 1].Id; Id accessoryCleaverId = [SELECT Id FROM Accessory__c WHERE Name='241 - Ceramic Fiber Cleavers (set of 3) 1” x 1”' Limit 1].Id; Id accessoryStripperId = [SELECT Id FROM Accessory__c WHERE Name='134 - Fiber Stripping Tool' Limit 1].Id; List<Accessory_Item__c> Accessories = new List<Accessory_Item__c>(); for (Case c : Trigger.New) { if (c.Quick_Order__c == '360 Fiber') { Accessories.add(new Accessory_Item__c( Case__c = c.Id, Item__c = accessory360Id)); } Else if (c.Quick_Order__c == 'Cleaver') { Accessories.add(new Accessory_Item__c( Case__c = c.Id, Item__c = accessoryCleaverId)); } Else if (c.Quick_Order__c == 'Fiber Stripper'){ Accessories.add(new Accessory_Item__c( Case__c = c.Id, Item__c = accessoryStripperId)); } } insert Accessories; }Below is what I currently have for the test class however, it is still failing while atempting to test. The Id's that I am referencing are part of the 360 fiber Id and the only account that I have in my sandbox. I have read a little bit into the system.assert is this something I am missing?
@isTest public class TestQuickUpdate { static testMethod void insertNewRecord() { Case recordToCreate = new Case(); recordToCreate.Origin = 'Phone'; recordToCreate.AccountId = '001W000000I931R'; recordToCreate.Site__c = 'a0EW0000000fLBY'; recordToCreate.Quick_Order__c = '360 Fiber'; recordToCreate.ContactId = '003W000000OAOFK'; insert recordToCreate; } }
The failure message that I am getting right now is below:
Thank you for any assistance that is provided.

Use this as a reference.