@@ -10,7 +10,7 @@ executors:
10
10
docker_layer_caching : true
11
11
12
12
jobs :
13
- magento-build :
13
+ magento-build-and-test :
14
14
executor :
15
15
name : magento-executor
16
16
parameters :
50
50
bin/cli git clone [email protected] :magento/magento2.git .
51
51
bin/cli git checkout tags/<< parameters.magento-version >>
52
52
bin/composer require "algolia/algoliasearch-magento-2:dev-${CIRCLE_BRANCH}"
53
+ bin/composer global require --dev phpunit/phpunit
53
54
- run :
54
55
name : Enable AlgoliaSearch extension
55
56
working_directory : ~/Sites
@@ -61,11 +62,28 @@ jobs:
61
62
command : |
62
63
bin/magento setup:di:compile
63
64
bin/magento module:status Algolia_AlgoliaSearch
65
+ - run :
66
+ name : Run Unit Tests and Unit Coverage
67
+ working_directory : ~/Sites
68
+ command : |
69
+ bin/test/unit vendor/algolia/algoliasearch-magento-2/Test/Unit
70
+ bin/test/unit-coverage vendor/algolia/algoliasearch-magento-2/Test/Unit
71
+ - run :
72
+ name : Copy test results to CircleCI
73
+ working_directory : ~/Sites
74
+ command : |
75
+ bin/copyfromcontainer dev/tests/unit/report
76
+ - store_artifacts :
77
+ path : ~/Sites/dev/tests/unit/report
78
+ destination : test-results
79
+ - store_test_results :
80
+ path : ~/Sites/dev/tests/unit/report
81
+
64
82
65
83
workflows :
66
- magento-build-and-test :
84
+ magento-build-and-test-workflow :
67
85
jobs :
68
- - magento-build :
86
+ - magento-build-and-test :
69
87
matrix :
70
88
parameters :
71
89
php-version : ["8.2"]
0 commit comments