File tree Expand file tree Collapse file tree 2 files changed +3
-7
lines changed
Expand file tree Collapse file tree 2 files changed +3
-7
lines changed Original file line number Diff line number Diff line change 55use StellarWP \Models \Model ;
66
77class MockModel extends Model {
8- protected $ properties = [
8+ protected static $ properties = [
99 'id ' => 'int ' ,
1010 'firstName ' => [ 'string ' , 'Michael ' ],
1111 'lastName ' => 'string ' ,
Original file line number Diff line number Diff line change @@ -110,9 +110,7 @@ public function testSetAttributeShouldAssignPropertyValue() {
110110 * @return void
111111 */
112112 public function testIsPropertyTypeValidShouldReturnTrueWhenPropertyIsValid () {
113- $ model = new MockModel ();
114-
115- $ this ->assertTrue ( $ model ->isPropertyTypeValid ( 'id ' , 1 ) );
113+ $ this ->assertTrue ( MockModel::isPropertyTypeValid ( 'id ' , 1 ) );
116114 }
117115
118116 /**
@@ -123,9 +121,7 @@ public function testIsPropertyTypeValidShouldReturnTrueWhenPropertyIsValid() {
123121 * @return void
124122 */
125123 public function testIsPropertyTypeValidShouldReturnFalseWhenPropertyIsInValid ( $ key , $ value ) {
126- $ model = new MockModel ();
127-
128- $ this ->assertFalse ( $ model ->isPropertyTypeValid ( $ key , $ value ) );
124+ $ this ->assertFalse ( MockModel::isPropertyTypeValid ( $ key , $ value ) );
129125 }
130126
131127 /**
You can’t perform that action at this time.
0 commit comments