Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP: Add uncommitted test files #9

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions force-app/main/default/pages/RollbarTest.page
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<apex:page controller="RollbarTestController">
<h1>Rollbar Test</h1>
<p>Press the button below to cause an exception.</p>
<apex:form >
<apex:commandButton action="{!test}" value="Throw exception" />
</apex:form>
</apex:page>
5 changes: 5 additions & 0 deletions force-app/main/default/pages/RollbarTest.page-meta.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<ApexPage xmlns="urn:metadata.tooling.soap.sforce.com" fqn="RollbarTest">
<apiVersion>47.0</apiVersion>
<label>RollbarTest</label>
</ApexPage>
7 changes: 7 additions & 0 deletions force-app/main/default/tests/RollbarTestController.cls
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
public with sharing class RollbarTestController {
public PageReference test() {
List<Account> aa = [SELECT Id, Name FROM Account WHERE Name = 'Acme'];
Account ac = aa[2];
return null;
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="UTF-8"?>
<ApexClass xmlns="http://soap.sforce.com/2006/04/metadata">
<apiVersion>45.0</apiVersion>
<status>Active</status>
</ApexClass>
10 changes: 7 additions & 3 deletions manifest/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,19 @@
<members>MetadataServiceTest</members>
<members>RollbarConfigureControllerTest</members>
<members>RollbarTest</members>
<members>RollbarTestController</members>

<!-- test helpers -->
<members>RollbarApiCalloutMock</members>
<members>DataBuilderTestException</members>
<members>DataBuilderTestException</members>
</types>

<types>
<name>ApexPage</name>
<members>RollbarConfigure</members>
<members>RollbarInstallationCheck</members>
<name>ApexPage</name>

<!-- test pages -->
<members>RollbarTest</members>
</types>
</Package>
</Package>