Update documentation

TRAVIS_JOB_NUMBER=3570.2
TRAVIS_COMMIT_RANGE=17ab453db976...895ee7bc9f94
This commit is contained in:
Travis CI (pmd-bot)
2019-03-25 19:35:38 +00:00
parent ecbe614a70
commit 7d8721d87b
4 changed files with 44 additions and 38 deletions

View File

@ -5,8 +5,8 @@
<description>Intended as a documentation theme based on Jekyll for technical writers documenting software and other technical products, this theme has all the elements you would need to handle multiple products with both multi-level sidebar navigation, tags, and other documentation features.</description>
<link>https://pmd.github.io/pmd/</link>
<atom:link href="https://pmd.github.io/pmd/feed.xml" rel="self" type="application/rss+xml"/>
<pubDate>Mon, 25 Mar 2019 19:18:44 +0000</pubDate>
<lastBuildDate>Mon, 25 Mar 2019 19:18:44 +0000</lastBuildDate>
<pubDate>Mon, 25 Mar 2019 19:34:31 +0000</pubDate>
<lastBuildDate>Mon, 25 Mar 2019 19:34:31 +0000</lastBuildDate>
<generator>Jekyll v3.7.4</generator>
</channel>

View File

@ -1286,8 +1286,9 @@ $('#toc').toc({ minimumHeaders: 0, listType: 'ul', showSpeed: 0, headers: 'h2,h3
<div class="bs-callout bs-callout-">Rules which enforce generally accepted best practices.</div>
<ul>
<li><a href="pmd_rules_apex_bestpractices.html#apexassertionsshouldincludemessage">ApexAssertionsShouldIncludeMessage</a>: The second parameter of System.assert/third parameter of System.assertEquals/System.assertNotEqua…</li>
<li><a href="pmd_rules_apex_bestpractices.html#apexunittestclassshouldhaveasserts">ApexUnitTestClassShouldHaveAsserts</a>: Apex unit tests should include at least one assertion. This makes the tests more robust, and usi…</li>
<li><a href="pmd_rules_apex_bestpractices.html#apexunittestmethodshouldhaveistestannotation">ApexUnitTestMethodShouldHaveIsTestAnnotation</a>: Apex test methods should have @isTest annotation. As testMethod keyword is deprecated,…</li>
<li><a href="pmd_rules_apex_bestpractices.html#apexunittestmethodshouldhaveistestannotation">ApexUnitTestMethodShouldHaveIsTestAnnotation</a>: Apex test methods should have @isTest annotation.As testMethod keyword is deprecated, Salesforce </li>
<li><a href="pmd_rules_apex_bestpractices.html#apexunittestshouldnotuseseealldatatrue">ApexUnitTestShouldNotUseSeeAllDataTrue</a>: Apex unit tests should not use @isTest(seeAllData=true) because it opens up the existing database…</li>
<li><a href="pmd_rules_apex_bestpractices.html#avoidglobalmodifier">AvoidGlobalModifier</a>: Global classes should be avoided (especially in managed packages) as they can never be deleted or…</li>
<li><a href="pmd_rules_apex_bestpractices.html#avoidlogicintrigger">AvoidLogicInTrigger</a>: As triggers do not allow methods like regular classes they are less flexible and suited to apply …</li>

View File

@ -5,7 +5,7 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="description" content="Rules which enforce generally accepted best practices.">
<meta name="keywords" content=" Best Practices, ApexUnitTestClassShouldHaveAsserts, ApexUnitTestShouldNotUseSeeAllDataTrue, AvoidGlobalModifier, AvoidLogicInTrigger, ApexUnitTestAssertStatement, ApexUnitTestMethodShouldHaveIsTestAnnotation">
<meta name="keywords" content=" Best Practices, ApexAssertionsShouldIncludeMessage, ApexUnitTestClassShouldHaveAsserts, ApexUnitTestMethodShouldHaveIsTestAnnotation, ApexUnitTestShouldNotUseSeeAllDataTrue, AvoidGlobalModifier, AvoidLogicInTrigger">
<title>Best Practices | PMD Source Code Analyzer</title>
<link rel="stylesheet" href="css/syntax.css">
@ -1281,16 +1281,17 @@ $('#toc').toc({ minimumHeaders: 0, listType: 'ul', showSpeed: 0, headers: 'h2,h3
<!-- DO NOT EDIT THIS FILE. This file is generated from file ../pmd-apex/src/main/resources/category/apex/bestpractices.xml. -->
<h2 id="apexunittestassertstatement">ApexUnitTestAssertStatement</h2>
<h2 id="apexassertionsshouldincludemessage">ApexAssertionsShouldIncludeMessage</h2>
<p><strong>Since:</strong> PMD 6.13.0</p>
<p><strong>Priority:</strong> Medium (3)</p>
<p>The second parameter of System.assert/third parameter of System.assertEquals/System.assertNotEquals is a message.
Having a second/third parameter provides more information and makes it easier to debug the test failure and improves the readability of test output.</p>
Having a second/third parameter provides more information and makes it easier to debug the test failure and
improves the readability of test output.</p>
<p><strong>This rule is defined by the following Java class:</strong> <a href="https://github.com/pmd/pmd/blob/master/pmd-apex/src/main/java/net/sourceforge/pmd/lang/apex/rule/bestpractices/ApexUnitTestAssertStatementRule.java">net.sourceforge.pmd.lang.apex.rule.bestpractices.ApexAssertionsShouldIncludeMessageRule</a></p>
<p><strong>This rule is defined by the following Java class:</strong> <a href="https://github.com/pmd/pmd/blob/master/pmd-apex/src/main/java/net/sourceforge/pmd/lang/apex/rule/bestpractices/ApexAssertionsShouldIncludeMessageRule.java">net.sourceforge.pmd.lang.apex.rule.bestpractices.ApexAssertionsShouldIncludeMessageRule</a></p>
<p><strong>Example(s):</strong></p>
@ -1320,27 +1321,27 @@ Having a second/third parameter provides more information and makes it easier to
<tbody>
<tr>
<td>cc_categories</td>
<td>Style</td>
<td>Code Climate Categories</td>
<td>Bug Risk</td>
<td><span style="border-radius: 0.25em; color: #fff; padding: 0.2em 0.6em 0.3em; display: inline; background-color: #d9534f; font-size: 75%;">Deprecated</span> Code Climate Categories</td>
<td>yes. Delimiter is |.</td>
</tr>
<tr>
<td>cc_remediation_points_multiplier</td>
<td>1</td>
<td>Code Climate Remediation Points multiplier</td>
<td>100</td>
<td><span style="border-radius: 0.25em; color: #fff; padding: 0.2em 0.6em 0.3em; display: inline; background-color: #d9534f; font-size: 75%;">Deprecated</span> Code Climate Remediation Points multiplier</td>
<td>no</td>
</tr>
<tr>
<td>cc_block_highlighting</td>
<td>false</td>
<td>Code Climate Block Highlighting</td>
<td><span style="border-radius: 0.25em; color: #fff; padding: 0.2em 0.6em 0.3em; display: inline; background-color: #d9534f; font-size: 75%;">Deprecated</span> Code Climate Block Highlighting</td>
<td>no</td>
</tr>
</tbody>
</table>
<p><strong>Use this rule by referencing it:</strong></p>
<div class="language-xml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nt">&lt;rule</span> <span class="na">ref=</span><span class="s">"category/apex/bestpractices.xml/ApexUnitTestAssertStatement"</span> <span class="nt">/&gt;</span>
<p><strong>Use this rule with the default properties by just referencing it:</strong></p>
<div class="language-xml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nt">&lt;rule</span> <span class="na">ref=</span><span class="s">"category/apex/bestpractices.xml/ApexAssertionsShouldIncludeMessage"</span> <span class="nt">/&gt;</span>
</code></pre></div></div>
<h2 id="apexunittestclassshouldhaveasserts">ApexUnitTestClassShouldHaveAsserts</h2>
@ -1425,6 +1426,10 @@ As testMethod keyword is deprecated, Salesforce advices to use @isTest annotatio
<span class="kd">static</span> <span class="kt">void</span> <span class="nf">methodBTest</span><span class="o">()</span> <span class="o">{</span>
<span class="o">}</span>
<span class="nd">@isTest</span> <span class="kd">static</span> <span class="kt">void</span> <span class="nf">methodCTest</span><span class="o">()</span> <span class="o">{</span>
<span class="n">System</span><span class="o">.</span><span class="na">assert</span><span class="o">(</span><span class="mi">1</span><span class="o">==</span><span class="mi">2</span><span class="o">);</span>
<span class="o">}</span>
<span class="nd">@isTest</span> <span class="kd">static</span> <span class="kt">void</span> <span class="nf">methodCTest</span><span class="o">()</span> <span class="o">{</span>
<span class="n">System</span><span class="o">.</span><span class="na">debug</span><span class="o">(</span><span class="err">'</span><span class="n">I</span> <span class="n">am</span> <span class="n">a</span> <span class="n">debug</span> <span class="n">statement</span><span class="err">'</span><span class="o">);</span>
<span class="o">}</span>
<span class="kd">private</span> <span class="kt">void</span> <span class="nf">fetchData</span><span class="o">()</span> <span class="o">{</span>
<span class="o">}</span>
@ -1445,26 +1450,26 @@ As testMethod keyword is deprecated, Salesforce advices to use @isTest annotatio
<tbody>
<tr>
<td>cc_categories</td>
<td>Style</td>
<td>Code Climate Categories</td>
<td>Bug Risk</td>
<td><span style="border-radius: 0.25em; color: #fff; padding: 0.2em 0.6em 0.3em; display: inline; background-color: #d9534f; font-size: 75%;">Deprecated</span> Code Climate Categories</td>
<td>yes. Delimiter is |.</td>
</tr>
<tr>
<td>cc_remediation_points_multiplier</td>
<td>1</td>
<td>Code Climate Remediation Points multiplier</td>
<td>100</td>
<td><span style="border-radius: 0.25em; color: #fff; padding: 0.2em 0.6em 0.3em; display: inline; background-color: #d9534f; font-size: 75%;">Deprecated</span> Code Climate Remediation Points multiplier</td>
<td>no</td>
</tr>
<tr>
<td>cc_block_highlighting</td>
<td>false</td>
<td>Code Climate Block Highlighting</td>
<td><span style="border-radius: 0.25em; color: #fff; padding: 0.2em 0.6em 0.3em; display: inline; background-color: #d9534f; font-size: 75%;">Deprecated</span> Code Climate Block Highlighting</td>
<td>no</td>
</tr>
</tbody>
</table>
<p><strong>Use this rule by referencing it:</strong></p>
<p><strong>Use this rule with the default properties by just referencing it:</strong></p>
<div class="language-xml highlighter-rouge"><div class="highlight"><pre class="highlight"><code><span class="nt">&lt;rule</span> <span class="na">ref=</span><span class="s">"category/apex/bestpractices.xml/ApexUnitTestMethodShouldHaveIsTestAnnotation"</span> <span class="nt">/&gt;</span>
</code></pre></div></div>

View File

@ -213,6 +213,15 @@
}
,
{
"title": "ApexAssertionsShouldIncludeMessage (Apex, Best Practices)",
"tags": "",
"keywords": "ApexAssertionsShouldIncludeMessage",
"url": "pmd_rules_apex_bestpractices.html#apexassertionsshouldincludemessage",
"summary": "Rules which enforce generally accepted best practices."
}
,
{
"title": "ApexUnitTestClassShouldHaveAsserts (Apex, Best Practices)",
"tags": "",
@ -222,6 +231,15 @@
}
,
{
"title": "ApexUnitTestMethodShouldHaveIsTestAnnotation (Apex, Best Practices)",
"tags": "",
"keywords": "ApexUnitTestMethodShouldHaveIsTestAnnotation",
"url": "pmd_rules_apex_bestpractices.html#apexunittestmethodshouldhaveistestannotation",
"summary": "Rules which enforce generally accepted best practices."
}
,
{
"title": "ApexUnitTestShouldNotUseSeeAllDataTrue (Apex, Best Practices)",
"tags": "",
@ -247,24 +265,6 @@
"url": "pmd_rules_apex_bestpractices.html#avoidlogicintrigger",
"summary": "Rules which enforce generally accepted best practices."
}
,
{
"title": "ApexUnitTestAssertStatement (Apex, Best Practices)",
"tags": "",
"keywords": "ApexUnitTestAssertStatement",
"url": "pmd_rules_apex_bestpractices.html#apexunittestassertstatement",
"summary": "Rules which enforce generally accepted best practices."
}
,
{
"title": "ApexUnitTestMethodShouldHaveIsTestAnnotation (Apex, Best Practices)",
"tags": "",
"keywords": "ApexUnitTestMethodShouldHaveIsTestAnnotation",
"url": "pmd_rules_apex_bestpractices.html#apexunittestmethodshouldhaveistestannotation",
"summary": "Rules which enforce generally accepted best practices."
}