File tree Expand file tree Collapse file tree 2 files changed +2
-11
lines changed
app/code/Magento/CatalogInventory Expand file tree Collapse file tree 2 files changed +2
-11
lines changed Original file line number Diff line number Diff line change @@ -148,7 +148,7 @@ public function __construct(
148
148
*/
149
149
public function getDefaultScopeId ()
150
150
{
151
- return ( int ) $ this -> storeManager -> getWebsite ()-> getId () ;
151
+ return 1 ;
152
152
}
153
153
154
154
/**
Original file line number Diff line number Diff line change @@ -59,18 +59,9 @@ protected function setUp()
59
59
);
60
60
}
61
61
62
- public function testGetDefaultWebsiteId ()
62
+ public function testGetDefaultScopeId ()
63
63
{
64
64
$ id = 1 ;
65
- $ websiteMock = $ this ->getMockBuilder ('Magento\Store\Model\Website ' )
66
- ->disableOriginalConstructor ()
67
- ->getMock ();
68
- $ websiteMock ->expects ($ this ->once ())
69
- ->method ('getId ' )
70
- ->willReturn ($ id );
71
- $ this ->storeManagerMock ->expects ($ this ->once ())
72
- ->method ('getWebsite ' )
73
- ->willReturn ($ websiteMock );
74
65
$ this ->assertEquals ($ id , $ this ->model ->getDefaultScopeId ());
75
66
}
76
67
You can’t perform that action at this time.
0 commit comments