File tree Expand file tree Collapse file tree 1 file changed +30
-0
lines changed
dev/tests/integration/testsuite/Magento/User/Model/ResourceModel/User Expand file tree Collapse file tree 1 file changed +30
-0
lines changed Original file line number Diff line number Diff line change
1
+ <?php
2
+ /**
3
+ * Copyright © Magento, Inc. All rights reserved.
4
+ * See COPYING.txt for license details.
5
+ */
6
+ namespace Magento \User \Model \ResourceModel \User ;
7
+
8
+ /**
9
+ * User collection test
10
+ * @magentoAppArea adminhtml
11
+ */
12
+ class CollectionTest extends \PHPUnit \Framework \TestCase
13
+ {
14
+ /**
15
+ * @var \Magento\User\Model\ResourceModel\User\Collection
16
+ */
17
+ protected $ _collection ;
18
+
19
+ protected function setUp (): void
20
+ {
21
+ $ this ->_collection = \Magento \TestFramework \Helper \Bootstrap::getObjectManager ()->create (
22
+ \Magento \User \Model \ResourceModel \User \Collection::class
23
+ );
24
+ }
25
+
26
+ public function testFilteringCollectionByUserId ()
27
+ {
28
+ $ this ->assertEquals (1 , $ this ->_collection ->addFieldToFilter ('user_id ' , 1 )->count ());
29
+ }
30
+ }
You can’t perform that action at this time.
0 commit comments