Questions tagged [testing]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
1
vote
1answer
26 views

not of type Boolean error message when testing Stripe in Test Mode

I am getting the following error message when testing Stripe recurring membership dues in test mode: Sorry, due to an error, we are unable to fulfill your request at the moment. You may want to ...
0
votes
1answer
39 views

Mailing_send_test - job_id is not valid

I am having a "Error in call to Mailing_send_test : job_id is not valid : 14" when I send test email in Mosaico (to one email or to a group) whereas email settings are working perfectly. My mailing ...
5
votes
1answer
40 views

how to write PHP Unit test for an entity using hooks

I am to write a unit test for a simple extension using hooks with postprocess and formbuild. How can I do it? Please provide some example.
9
votes
1answer
100 views

How to find out about changes in the latest Release Candidate?

We would like to help test the monthly CiviCRM Release Candidate (RC) versions to contribute to more reliable releases. I found out the RC are published here along with the stable releases, so e.g. ...
1
vote
1answer
25 views

How can I see all test data in CiviCRM?

I'm doing tests on a test server, but when I make changes using test data, the test data is hidden. I know this is by design, but it makes it impossible to actually check if things are working. I ...
3
votes
0answers
32 views

testing extensions without buildkit

We have a civicrm instance which we installed from the download page on civicrm.org, not via buildkit. We also have a bunch of custom extensions specific for our use case. Until now these extensions ...
3
votes
3answers
237 views

ER diagram for the latest Civicrm , Foreign key in Structure, test cases/plans

Where can I get the ER diagram for the latest CiviCRM? I need it for internal reporting purposes in our organization. I am able to download the Table structure from phpMyAdmin. However, it does not ...
0
votes
1answer
26 views

Creating a copy of CiviCRM on a test sub-domain (Wordpress)

I need simple step-by-step procedure to copy my current production site to a sub-domain on the same server, that we intend using for testing/development (its important that we retain all our custom ...
3
votes
2answers
45 views

How to reset the headless test db?

I'm using headless phpunit tests. I noticed that the first time I do this it pauses and says about installing schema for xxxx - a test database. If you break stuff enough, you can end up with a ...
2
votes
1answer
42 views

How to build a Real Size Drupal+Civi Test Configuration?

I have installed a Drupal+Civi test site, with same software level as my production site (Drupal 7.54 / Civi 4.7.16). To be able to make real size tests, I want to have identical DBs on each site. ...
1
vote
1answer
20 views

Quality assurance considerations for membership signups

I'm pretty new to the CiviCRM world and am just finishing my first project using it. We are now in the process of making sure that our membership signup procedure (with contributions) works well. As I ...
1
vote
0answers
51 views

Does CiviCRM have a recommended setting for zend.multibyte?

When running CiviCRM test suites, I see PHP Warning: declare(encoding=...) ignored because Zend multibyte feature is turned off by settings in /path/to/sites/all/modules/civicrm/vendor/...
2
votes
1answer
46 views

Can't accesss cv from CiviUnitTestCase::createExternalAPI in buildkit environment

I'm QAing https://github.com/civicrm/civicrm-core/pull/9255 and trying to run a couple of relevant test locally: ~/src/civicrm-buildkit/build/qa/sites/all/modules/civicrm$ tools/scripts/phpunit ...
1
vote
1answer
36 views

Can cv handle custom Wordpress installs?

A wordpress install I'm adding CiviCRM to is setup in a non-standard way, specifically: docroot \- civicrm.settings.php \- wp-config.php \- content/ | \- plugins | | \- civicrm | \- uploads | \...
4
votes
2answers
69 views

How to bootstrap CiviCRM with admin permissions in a Wordpress environment?

I'm using eval cv php:boot in a script. I need to be able to delete a contact in the script, including the skip_undelete flag, but this action is denied - get a "could not delete contact" error. I ...
4
votes
2answers
69 views

Can I mock the CiviCRM API for unit tests?

Suppose I want to mock the API in unit tests for my extension, can I do that? Or should I implement an interface myself that is just a wrapper around civicrm_api3, and create mocks of that interface? ...
2
votes
2answers
26 views

How to write unit tests for methods thsat echo instead of return (e.g., AJAX call handlers)

There are several methods in CiviCRM that just print their output directly to the buffer and then exit, because they're just sending an HTML snippet or other response for an AJAX call. For example, ...
5
votes
1answer
66 views

Easy way to read email on staging sites?

Staging and development sites typically have real outbound email turned off, and for good reason (see https://wiki.civicrm.org/confluence/display/CRMDOC/Moving+CiviCRM+instance+from+production+to+...
5
votes
1answer
71 views

How to test for CiviCRM status messages in selenium?

CiviCRM presents status messages in a slick overlay, which looks neat for human users but has been hard for me to test for in Selenium. It appears the messages first appear within the main page ...
5
votes
1answer
182 views

Testing a module which uses CiviCRM php api

I have written a drupal module that uses the CiviCRM api. I want to build tests for my module. Drupal 7 includes the simpletest module in core, so I'm using that. I have created the following test: ...
1
vote
3answers
101 views

Command failed (cv php:boot --level=settings) when trying to run tests

I'm trying to run CiviCRM's unit tests, but I hit on this error when running scripts/phpunit AllTests: RuntimeException: Command failed (cv php:boot --level=settings) in ...tests\phpunit\CiviTest\...
2
votes
0answers
25 views

Subscriber User on WordPress Demo Site

I've been running into a few issues on my CiviCRM installs that would be nice to test against the demo site. However, because there is no subscriber level user on the demo, and I can't seem to create ...
9
votes
1answer
86 views

What versions of PHP are used in CiviCRM's internal QA?

The wiki currently states that CiviCRM has bare minimum (5.3.10) and recommended (>= 5.4) PHP requirements. Knowing what CiviCRM has been tested with can help identify what should be expected to work ...
2
votes
1answer
219 views

Is it possible to use Windows & Cygwin to run Selenium tests or does Selenium require a VM?

I know documentation suggests using a virtual machine w/Windows, but I don't know anything (yet) about Selenium /limitations so am asking