Added first few test cases
This commit is contained in:
@@ -78,6 +78,7 @@ class LiteDb
|
||||
call_user_func($upgradeHandler, $this, $this->version);
|
||||
// Write the new version number to the database
|
||||
$this->dbSetMeta(self::META_SCHEMA_VERSION, $version);
|
||||
$this->version = $version;
|
||||
}
|
||||
|
||||
// Refresh the database version, for debug purposes
|
||||
@@ -179,6 +180,16 @@ class LiteDb
|
||||
return $this->stores[$storeName];
|
||||
}
|
||||
|
||||
public function hasStore(string $storeName): bool
|
||||
{
|
||||
return array_key_exists($storeName, $this->storeMeta);
|
||||
}
|
||||
|
||||
public function getVersion(): int
|
||||
{
|
||||
return $this->version;
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
* @param string
|
||||
|
||||
Reference in New Issue
Block a user