You need to sign in to do that
Don't have an account?
farah sherif
How to add an asset to a certain account in apex?
How to add an asset to a certain account in apex?
@isTest
private class AssetTriggerTest{
@isTest static void testclass(){
Account acc = new Account();
acc.Name = 'farah test';
insert acc;
}
}
@isTest
private class AssetTriggerTest{
@isTest static void testclass(){
Account acc = new Account();
acc.Name = 'farah test';
insert acc;
}
}
ID accountid = [SELECT ID, Name FROM Account WHERE Name =:'farah test' LIMIT 1].ID;
system.assertequals(accountid, acc.id);
} catch (Exception e){
system.debug('error account not found ' + + e.getMessage());
}