-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- standard format - fixed test names for some files (copy-paste moment)
- Loading branch information
1 parent
db2c05d
commit 0a335fa
Showing
7 changed files
with
41 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
import construct | ||
|
||
from mercury_engine_data_structures.formats import standard_format | ||
from mercury_engine_data_structures.formats.base_resource import BaseResource | ||
from mercury_engine_data_structures.game_check import Game | ||
|
||
BPTDAT = standard_format.create('CPlaythrough', "1.0.2") | ||
BPTDEF = standard_format.create('CPlaythroughDef', "1.0.2") | ||
|
||
class Bptdat(BaseResource): | ||
@classmethod | ||
def construct_class(cls, target_game: Game) -> construct.Construct: | ||
return BPTDAT | ||
|
||
class Bptdef(BaseResource): | ||
@classmethod | ||
def construct_class(cls, target_game: Game) -> construct.Construct: | ||
return BPTDEF |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import pytest | ||
from tests.test_lib import parse_build_compare_editor | ||
|
||
from mercury_engine_data_structures import dread_data | ||
from mercury_engine_data_structures.formats.bptdat import Bptdat, Bptdef | ||
|
||
|
||
@pytest.mark.parametrize("bptdat_path", dread_data.all_files_ending_with(".bptdat")) | ||
def test_bptdat(dread_file_tree, bptdat_path): | ||
parse_build_compare_editor(Bptdat, dread_file_tree, bptdat_path) | ||
|
||
@pytest.mark.parametrize("bptdef_path", dread_data.all_files_ending_with(".bptdef")) | ||
def test_bptdef(dread_file_tree, bptdef_path): | ||
parse_build_compare_editor(Bptdef, dread_file_tree, bptdef_path) |