projects
/
civicrm-core.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge pull request #19525 from eileenmcnaughton/member_soft
[civicrm-core.git]
/
tests
/
phpunit
/
CRM
/
Core
/
PseudoConstantTest.php
diff --git
a/tests/phpunit/CRM/Core/PseudoConstantTest.php
b/tests/phpunit/CRM/Core/PseudoConstantTest.php
index ad76024aeec1a5142e8e250871b65302a7b728d1..36a1dc33b73bb98b1d3ba0f35e2c31300d6fc0ae 100644
(file)
--- a/
tests/phpunit/CRM/Core/PseudoConstantTest.php
+++ b/
tests/phpunit/CRM/Core/PseudoConstantTest.php
@@
-81,15
+81,6
@@
class CRM_Core_PseudoConstantTest extends CiviUnitTestCase {
];
$result = civicrm_api3('payment_processor', 'create', $api_params);
];
$result = civicrm_api3('payment_processor', 'create', $api_params);
- // Create a Campaign for testing.
- $campaign_name = md5(microtime());
- $api_params = [
- 'title' => $campaign_name,
- 'is_active' => TRUE,
- 'status_id' => 2,
- ];
- $result = civicrm_api3('campaign', 'create', $api_params);
-
// Create a membership type for testing.
$membership_type = md5(microtime());
$api_params = [
// Create a membership type for testing.
$membership_type = md5(microtime());
$api_params = [
@@
-243,10
+234,6
@@
class CRM_Core_PseudoConstantTest extends CiviUnitTestCase {
'fieldName' => 'medium_id',
'sample' => 'Phone',
],
'fieldName' => 'medium_id',
'sample' => 'Phone',
],
- [
- 'fieldName' => 'campaign_id',
- 'sample' => $campaign_name,
- ],
],
'CRM_Campaign_DAO_Campaign' => [
[
],
'CRM_Campaign_DAO_Campaign' => [
[
@@
-261,10
+248,6
@@
class CRM_Core_PseudoConstantTest extends CiviUnitTestCase {
],
],
'CRM_Campaign_DAO_Survey' => [
],
],
'CRM_Campaign_DAO_Survey' => [
- [
- 'fieldName' => 'campaign_id',
- 'sample' => $campaign_name,
- ],
[
'fieldName' => 'activity_type_id',
'sample' => 'Phone Call',
[
'fieldName' => 'activity_type_id',
'sample' => 'Phone Call',
@@
-272,10
+255,6
@@
class CRM_Core_PseudoConstantTest extends CiviUnitTestCase {
],
],
'CRM_Campaign_DAO_CampaignGroup' => [
],
],
'CRM_Campaign_DAO_CampaignGroup' => [
- [
- 'fieldName' => 'campaign_id',
- 'sample' => $campaign_name,
- ],
[
'fieldName' => 'group_type',
'sample' => 'Include',
[
'fieldName' => 'group_type',
'sample' => 'Include',
@@
-499,10
+478,6
@@
class CRM_Core_PseudoConstantTest extends CiviUnitTestCase {
'fieldName' => 'payment_instrument_id',
'sample' => 'Check',
],
'fieldName' => 'payment_instrument_id',
'sample' => 'Check',
],
- [
- 'fieldName' => 'campaign_id',
- 'sample' => $campaign_name,
- ],
],
'CRM_Pledge_DAO_PledgePayment' => [
[
],
'CRM_Pledge_DAO_PledgePayment' => [
[
@@
-525,10
+500,6
@@
class CRM_Core_PseudoConstantTest extends CiviUnitTestCase {
'fieldName' => 'frequency_unit',
'sample' => 'month',
],
'fieldName' => 'frequency_unit',
'sample' => 'month',
],
- [
- 'fieldName' => 'campaign_id',
- 'sample' => $campaign_name,
- ],
],
'CRM_PCP_DAO_PCP' => [
[
],
'CRM_PCP_DAO_PCP' => [
[
@@
-778,10
+749,6
@@
class CRM_Core_PseudoConstantTest extends CiviUnitTestCase {
'sample' => ['USD' => 'US Dollar'],
'max' => 200,
],
'sample' => ['USD' => 'US Dollar'],
'max' => 200,
],
- [
- 'fieldName' => 'campaign_id',
- 'sample' => $campaign_name,
- ],
],
'CRM_Event_DAO_Event' => [
[
],
'CRM_Event_DAO_Event' => [
[
@@
-809,10
+776,6
@@
class CRM_Core_PseudoConstantTest extends CiviUnitTestCase {
'sample' => ['USD' => 'US Dollar'],
'max' => 200,
],
'sample' => ['USD' => 'US Dollar'],
'max' => 200,
],
- [
- 'fieldName' => 'campaign_id',
- 'sample' => $campaign_name,
- ],
],
'CRM_Core_DAO_Menu' => [
[
],
'CRM_Core_DAO_Menu' => [
[
@@
-833,10
+796,6
@@
class CRM_Core_PseudoConstantTest extends CiviUnitTestCase {
'fieldName' => 'status_id',
'sample' => 'New',
],
'fieldName' => 'status_id',
'sample' => 'New',
],
- [
- 'fieldName' => 'campaign_id',
- 'sample' => $campaign_name,
- ],
],
'CRM_Member_DAO_MembershipStatus' => [
[
],
'CRM_Member_DAO_MembershipStatus' => [
[
@@
-891,10
+850,6
@@
class CRM_Core_PseudoConstantTest extends CiviUnitTestCase {
'fieldName' => 'visibility',
'sample' => 'Public Pages',
],
'fieldName' => 'visibility',
'sample' => 'Public Pages',
],
- [
- 'fieldName' => 'campaign_id',
- 'sample' => $campaign_name,
- ],
],
'CRM_Mailing_DAO_MailingComponent' => [
[
],
'CRM_Mailing_DAO_MailingComponent' => [
[
@@
-967,10
+922,6
@@
class CRM_Core_PseudoConstantTest extends CiviUnitTestCase {
'fieldName' => 'contribution_page_id',
'sample' => $contribution_page,
],
'fieldName' => 'contribution_page_id',
'sample' => $contribution_page,
],
- [
- 'fieldName' => 'campaign_id',
- 'sample' => $campaign_name,
- ],
],
'CRM_Contribute_DAO_PremiumsProduct' => [
[
],
'CRM_Contribute_DAO_PremiumsProduct' => [
[
@@
-992,10
+943,6
@@
class CRM_Core_PseudoConstantTest extends CiviUnitTestCase {
'sample' => ['USD' => 'US Dollar'],
'max' => 200,
],
'sample' => ['USD' => 'US Dollar'],
'max' => 200,
],
- [
- 'fieldName' => 'campaign_id',
- 'sample' => $campaign_name,
- ],
],
'CRM_Case_DAO_Case' => [
[
],
'CRM_Case_DAO_Case' => [
[
@@
-1102,7
+1049,7
@@
class CRM_Core_PseudoConstantTest extends CiviUnitTestCase {
];
CRM_Financial_BAO_FinancialTypeAccount::add($financialAccountParams);
$taxRates = CRM_Core_PseudoConstant::getTaxRates();
];
CRM_Financial_BAO_FinancialTypeAccount::add($financialAccountParams);
$taxRates = CRM_Core_PseudoConstant::getTaxRates();
- $this->assertEquals('5.00',
$taxRates[$financialType['id']]
);
+ $this->assertEquals('5.00',
round($taxRates[$financialType['id']], 2)
);
}
}
}
}