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

cost and currency properties can be undefined #41

Open
ewallah opened this issue Nov 29, 2024 · 0 comments
Open

cost and currency properties can be undefined #41

ewallah opened this issue Nov 29, 2024 · 0 comments

Comments

@ewallah
Copy link

ewallah commented Nov 29, 2024

There is no check if cost and currency are set.

As a result some reports built with reportbuilder and the core_course PHPUNIT tests fail:

participants_test (core_course\reportbuilder\datasource\participants_test)
✔ Datasource default [411.50 ms]
✘ Datasource non default columns [510.15 ms]

│ Undefined property: stdClass::$cost

│ enrol/wallet/lib.php:193
│ enrol/classes/reportbuilder/local/entities/enrol.php:122
│ reportbuilder/classes/local/report/column.php:698
│ reportbuilder/classes/table/custom_report_table.php:209
│ reportbuilder/tests/helpers.php:55
│ course/tests/reportbuilder/datasource/participants_test.php:199
│ lib/phpunit/classes/advanced_testcase.php:76

✔ Course last access aggregation [306.33 ms]
✔ Completion days taking course aggregation [470.45 ms]
✔ Datasource filters with data set #0 [422.17 ms]
✔ Datasource filters with data set #1 [416.77 ms]
✔ Datasource filters with data set #2 [409.21 ms]
✔ Datasource filters with data set #3 [408.47 ms]
✔ Datasource filters with data set #4 [422.21 ms]
✔ Datasource filters with data set #5 [426.89 ms]
✔ Datasource filters with data set #6 [417.81 ms]
✔ Datasource filters with data set #7 [425.02 ms]
✔ Datasource filters with data set #8 [442.55 ms]
✔ Datasource filters with data set #9 [434.12 ms]
✔ Datasource filters with data set #10 [435.77 ms]
✔ Datasource filters with data set #11 [410.45 ms]
✔ Datasource filters with data set #12 [423.98 ms]
✔ Datasource filters with data set #13 [430.42 ms]
✔ Datasource filters with data set #14 [413.47 ms]
✔ Datasource filters with data set #15 [425.26 ms]
↩ Stress datasource [68.00 ms]

│ PHPUNIT_LONGTEST is not defined

│ course/tests/reportbuilder/datasource/participants_test.php:522
│ lib/phpunit/classes/advanced_testcase.php:76

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant