From 1099b3f022c8bfe6f59119756d337fc5c14c54af Mon Sep 17 00:00:00 2001 From: Petr Skoda Date: Sun, 3 Apr 2022 10:22:42 +0200 Subject: [PATCH] MDL-74416 phpunit: fix generator counters reset --- lib/testing/generator/data_generator.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/lib/testing/generator/data_generator.php b/lib/testing/generator/data_generator.php index 7948bd15873..a07d7b2a381 100644 --- a/lib/testing/generator/data_generator.php +++ b/lib/testing/generator/data_generator.php @@ -87,10 +87,18 @@ EOD; * @return void */ public function reset() { + $this->gradecategorycounter = 0; + $this->gradeitemcounter = 0; + $this->gradeoutcomecounter = 0; $this->usercounter = 0; $this->categorycount = 0; + $this->cohortcount = 0; $this->coursecount = 0; $this->scalecount = 0; + $this->groupcount = 0; + $this->groupingcount = 0; + $this->rolecount = 0; + $this->tagcount = 0; foreach ($this->generators as $generator) { $generator->reset();