Do not validate .model.json files with no content/whitespace only (#420)

* Ignore empty/whitespace-only model.json files

* Ignore no return value from model.json files during snapshot

* Use str::from_utf8 instead of String::from_utf8

* Revert "Ignore no return value from model.json files during snapshot"

This reverts commit 0aef16e30a.

* Add test for empty .model.json files

* Change empty .model.json check method

Co-authored-by: Lucien Greathouse <me@lpghatguy.com>

* Format code with cargo fmt

* Use raw string instead

Co-authored-by: Lucien Greathouse <me@lpghatguy.com>
This commit is contained in:
Mixu78
2021-05-14 23:16:05 +03:00
committed by GitHub
parent 7599ef6626
commit ca8865a3ce
8 changed files with 130 additions and 2 deletions

View File

@@ -0,0 +1,6 @@
{
"name": "empty_folder",
"tree": {
"$path": "src"
}
}