24 Commits

Author SHA1 Message Date
Ellwood Zwovic
ee0bbca8e5 Move package manager to blender branch
Moved the package manger out of an addon. It now lives here:
https://developer.blender.org/diffusion/B/browse/soc-2017-package_manager/

This repository still contains the repo generation script, the readme
has been updated to reflect this.
2017-08-29 04:30:49 -07:00
Ellwood Zwovic
acd0792b28 Give repo generation tool clearer name 2017-07-14 17:09:30 -07:00
gandalf3
bbc1c8b3bf Rename "blenderpack" module to "bpackage"
Also split code into files by class
2017-07-06 22:58:17 -07:00
gandalf3
6db5a2d190 Update tests for previous commit 2017-07-06 22:12:43 -07:00
gandalf3
0f96cd4852 Add Repository and Package classes 2017-07-06 22:11:43 -07:00
gandalf3
b144e6a025 Remove unneccesary bulk of code in addons used for testing 2017-07-06 00:00:43 -07:00
gandalf3
f20264c963 Cleanup: Changes suggested by @sybren 2017-07-05 18:40:32 -07:00
gandalf3
1cefb4eab6 First test for conditional requests
Involves lots of mocking. Part of the issue is that there is no way (?) to
know where repo.json is stored when blender isn't running the show.
2017-07-05 02:45:30 -07:00
gandalf3
3847cc877f Improve make_repo.py
This cleans up make_repo.py a bit, using file extensions to determine
file type.

This also loosens the testing repo generation, as the existing
test required matching a predifed expected output which had to be
updated on every change (essentially making it a moot test, as the
reference output was obtained from the functions output).
The new test just checks if the output has the same number of packages
as the input dir has addons.

Tips on how best to test these sorts of "higher level" functions (if at
all) would be welcome :)
2017-07-04 23:56:19 -07:00
gandalf3
5ad139ac13 Quick hack to handle case of non-text, non-python files 2017-07-02 18:39:58 -07:00
gandalf3
9f0ff11421 Get all tests for make_repo.py passing 2017-07-02 16:55:17 -07:00
gandalf3
8baacc366b Split repo generation functionality out of blenderpack.py
Moved repo.json generation to make_repo.py
Package/addon parsing is getting a bit messy, this can be
cleaned up when we have a clearer idea of what a package is.

For now just make it work.
2017-07-02 15:15:48 -07:00
gandalf3
6a538a4264 Repo generation: add more testcases 2017-06-30 20:10:33 -07:00
gandalf3
354523f26b Write repo.json to current working directory 2017-06-30 15:08:07 -07:00
gandalf3
89ca306299 Cleanup: Remove commented code, use logging 2017-06-29 21:44:18 -07:00
gandalf3
2268925733 Testing: use try/finally to ensure repo.json is always cleaned up 2017-06-29 02:18:52 -07:00
gandalf3
5a0aba8a56 Cleanup: take advantage of pathlib
* Use / syntax for concating pathlib paths in tests
* Use .name for getting last component of pathlib path
2017-06-29 02:11:43 -07:00
4b7feeebb1 Switch to pathlib 2017-06-23 20:05:10 -07:00
8d8c3b84fd Repo generation: log and keep going on error
* Delete old report() functions, use logging instead
* Skip addons which have problems (but give a warning)
2017-06-23 19:10:26 -07:00
d06af2fed0 Clean up tests
No need to test on complete addons.
This commit adds a few test cases and some automated test
generation.
2017-06-23 18:53:07 -07:00
5a9a3db016 Initial implementation of repo generation tool 2017-06-22 20:04:15 -07:00
020ce924c6 Test for an invalid case 2017-06-22 18:00:29 -07:00
20683af72c More unit tests
Copy in a multifile addon for testing, also fix a typo in blenderpack.py
2017-06-22 17:49:56 -07:00
44e0a904a4 Pull some code in from 2016 project; add tests 2017-06-22 17:41:41 -07:00