mirror of
https://github.com/godotengine/godot-blender-exporter.git
synced 2026-01-04 14:09:56 +03:00
The existing script had some limitations: - It expected a certain level of nesting, and failed for tests/test_scenes/material_cycle/material_spatial/ due to the extra level of nesting - It only copied `.escn` files, but we actually need to make sure other files (like `.png` textures) are produced - It would not clean up files left behind from prior runs. For example, if an update failed to produce a `.png`, but we had it left from the prior run, we wouldn't notice. The `rm`/`cp` approach is simpler and solves these problems.
37 lines
733 B
Makefile
37 lines
733 B
Makefile
PYLINT = pylint
|
|
PEP8 = pycodestyle
|
|
BLENDER = blender
|
|
GODOT = godot
|
|
|
|
.DEFAULT_GOAL := all
|
|
|
|
pylint:
|
|
$(PYLINT) io_scene_godot
|
|
|
|
pep8:
|
|
$(PEP8) io_scene_godot
|
|
|
|
|
|
export-blends:
|
|
mkdir -p ./tests/godot_project/exports/
|
|
rm -rf ./tests/godot_project/.import # Ensure we don't have any hangover data
|
|
$(BLENDER) -b --python ./tests/export_test_scenes.py
|
|
|
|
|
|
test-import: export-blends
|
|
$(GODOT) -e -q --path tests/ > log.txt 2>&1
|
|
@cat log.txt
|
|
! grep -q "ERROR" log.txt
|
|
|
|
|
|
update-examples:
|
|
rm -r tests/reference_exports/*
|
|
cp -r tests/godot_project/exports/* tests/reference_exports/
|
|
|
|
compare: export-blends
|
|
diff -x "*.escn.import" -rq tests/godot_project/exports/ tests/reference_exports/
|
|
|
|
style-test: pep8 pylint
|
|
|
|
all: compare style-test
|