feat: localize tags and genres; improve search, duration and sorting
CI / test (push) Successful in 27s
CI / test (push) Successful in 27s
This commit is contained in:
1 parent
ea3074e0a9
commit
be4fbf6864
31 files changed
+1126
-145
No files matched your search
@@ -62,11 +62,16 @@ class SchemaVersionTests(unittest.TestCase):
|
||||
db.init(con)
|
||||
self.assertEqual(self._version(con), str(db.SCHEMA_VERSION))
|
||||
self.assertIn("source_appid", self._columns(con, "game_details"))
|
||||
self.assertIn("name_ru", self._columns(con, "tag_names"))
|
||||
tables = {r[0] for r in con.execute("SELECT name FROM sqlite_master WHERE type='table'")}
|
||||
self.assertIn("personal", tables)
|
||||
self.assertIn("game_translations", tables)
|
||||
self.assertIn("reco_feedback", tables)
|
||||
self.assertIn("game_fts", tables)
|
||||
self.assertIn("genre_names", tables)
|
||||
self.assertEqual(
|
||||
con.execute("SELECT name_ru FROM genre_names WHERE name='RPG'").fetchone()[0],
|
||||
"Ролевые игры")
|
||||
self.assertIn("estimated_hours", self._columns(con, "games"))
|
||||
self.assertIn("hltb_main", self._columns(con, "games"))
|
||||
self.assertIn("hltb_complete", self._columns(con, "games"))
|
||||
@@ -87,6 +92,7 @@ class SchemaVersionTests(unittest.TestCase):
|
||||
|
||||
self.assertEqual(self._version(con), str(db.SCHEMA_VERSION))
|
||||
self.assertIn("source_appid", self._columns(con, "game_details"))
|
||||
self.assertIn("name_ru", self._columns(con, "tag_names"))
|
||||
row = con.execute("SELECT name FROM games WHERE appid=100").fetchone()
|
||||
self.assertEqual(row["name"], "Legacy")
|
||||
details = con.execute("SELECT short_description, source_appid FROM game_details WHERE appid=100").fetchone()
|
||||
|
||||
Reference in new issue
Block a user