| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Now the the node monitor waits for all shards of the file,
which was modified on a remote computer, to arrive on this
computer, before it re-constructs the file into the respective
location in the combox directory.
- Tests for it is at
tests.events_test.TestEvents.test_NDM_onmodified method.
modified: combox/events.py
modified: tests/events_test.py
Part of this was done while listening to Avril's "Complicated" ; I
think this is the only modern Pop song which I like.
|
|
|
|
|
|
|
| |
this computer, its info is removed from the 'file_created' dictionary in the silo.
modified: combox/events.py
modified: tests/events_test.py
|
|
|
|
|
|
|
|
|
|
|
| |
The method removes information about a file in the category `type_'
where `type_' can be 'file_created', 'file_modified', 'file_removed',
'file_moved'.
Also wrote tests for it :~(
modified: combox/silo.py
modified: tests/silo_test.py
|
|
|
|
| |
modified: tests/events_test.py
|
|
|
|
|
|
| |
tests.events_test.TestEvents.test_NDM_oncreated.
modified: tests/events_test.py
|
|
|
|
|
|
| |
tests.event_test.TestEvents.
modified: tests/events_test.py
|
|
|
|
|
|
| |
the silo is purged using the deldb method instead of doing a os.remove.
modfied: tests/events_test.py
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Now the the node monitor waits for all shards of the file, which
was created on a remote computer, to arrive on this computer, before
it re-constructs the file into the respective location in the combox
directory.
- Tests for it is at tests.events_test.TestEvents.test_NDM_oncreate
method.
- The main test method, tests.events_test.TestEvents.test_NDM, was
disabled by renaming it to tests.events_test.TestEvents.test_NDM.
- Now the NodeDirMonitor requires passing the 'node monitor lock' when
creating an instance of it.
:~(
modified: combox/events.py
modified: tests/events_test.py
|
|
|
|
|
|
|
|
|
| |
This method now returns relative paths w. r. t all node directories. Before it used to return relative paths only w. r. t the first node directory.
Also updated the tests for it :~(
modified: combox/file.py
modified: tests/file_test.py
|
|
|
|
|
|
|
| |
`num_nodes' a value that represents the number of node directories.
modified: combox/events.py
modified: tests/events_test.py
|
|
|
|
|
|
|
|
| |
The main zarking reason for the name is that we might also want to
track directories apart from shards in the node directories.
modified: combox/silo.py
modified: tests/silo_test.py
|
|
|
|
|
|
|
|
| |
modified: combox/cbox.py
modified: combox/events.py
modified: combox/silo.py
modified: tests/events_test.py
modified: tests/silo_test.py
|
|
|
|
|
|
|
|
| |
These methods will be used to manage the dictionaries in the db
related to the zarking shards.
modified: combox/silo.py
modified: tests/silo_test.py
|
|
|
|
|
|
|
| |
wrote tests for it too :~(
modified: combox/events.py
modified: tests/events_test.py
|
|
|
|
|
|
|
| |
shards/directories in node directories.
modified: combox/file.py
modified: tests/file_test.py
|
|
|
|
|
|
|
|
| |
a function.
modified: tests/events_test.py
modified: tests/file_test.py
modified: tests/utils.py
|
|
|
|
|
|
|
| |
As usual, wrote correponding tests for it; zarking TDD or whatever :~|
modified: combox/events.py
modified: tests/events_test.py
|
|
|
|
| |
test method.
|
|
|
|
|
| |
modified: combox/events.py
modified: tests/events_test.py
|
|
|
|
|
|
|
|
|
|
|
| |
It has a third argument (boolean) which tells whether `cb_path' (the
first argument) is a file or not.
Updated the test for node_path function + code wherever node_path was used.
modified: combox/events.py
modified: combox/file.py
modified: tests/file_test.py
|
| |
|
|
|
|
|
|
|
| |
As usual, wrote correponding tests for it :|
modified: combox/events.py
modified: tests/events_test.py
|
|
|
|
|
|
|
|
| |
rm_path deletes a file or an empty directory.
updated the test for it too.
modified: tests/file_test.py
|
|
|
|
|
|
|
| |
wrote test for it too.
modified: combox/file.py
modified: tests/file_test.py
|
|
|
|
|
|
|
| |
also wrote test for it.
modified: combox/file.py
modified: tests/file_test.py
|
|
|
|
|
| |
modified: combox/events.py
modified: tests/events_test.py
|
| |
|
|
|
|
|
|
|
|
|
|
| |
- `file_content' is set to None by default
- If `file_content' is not None, hash of this is returned.
Updated the test for hash_file function.
modified: combox/file.py
modified: tests/file_test.py
|
|
|
|
|
|
|
|
| |
- the arg `fhash' is set to None by default.
- if `fhash' is not None, it is considered as file's current hash.
modified: combox/silo.py
modified: tests/silo_test.py
|
|
|
|
|
| |
Added code to test the new arg `write' in the decrypt_and_glue
function.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This function takes the path to the file in the combox and returns the
path of its first shard in the node directory. If the the given
argument is a directory (inside the combox directory), the function
returns the corresponding path of the directory under the first node
directory.
Test for the function was also written.
modified: combox/file.py
modified: tests/file_test.py
|
|
|
|
|
|
|
|
|
|
| |
At the moment only the on_created method of this class is kinda fleshed
out.
The tests for this class is at tests.events_test.TestEvents.test_NDM
modified: combox/events.py
modified: tests/events_test.py
|
|
|
|
| |
This method now checks if the `silo.db' exists before deleting it.
|
|
|
|
|
|
|
|
|
|
|
| |
directory.
It returns the path of the respective file or directory in the combox directory.
Also updated the test for this function at tests.file_test.TestFile.test_cbpath
modified: combox/file.py
modified: tests/file_test.py
|
|
|
|
| |
EventsTest class.
|
|
|
|
|
| |
- The teardown method is invoked after the end of each test in the TestEvents class.
- At the moment the teardown method just purges the node directories.
|
|
|
|
|
| |
- rm_nodedirs now calls purge_nodedirs and then deletes the node directories.
- purge_nodedirs function just purges the contents of the node directories.
|
|
|
|
|
|
|
|
|
|
| |
This function, given the path of a file shard, returns the
corresponding path of the file in the combox directory.
The test for this function is at tests.file_test.TestFile.test_cbpath
modified: combox/file.py
modified: tests/file_test.py
|
|
|
|
| |
construct pathnames.
|
|
|
|
|
|
|
|
|
|
| |
Now the function is rigged up to return path relative to both combox
directory and node directory.
Corresponding test for this function is at tests.file_test module.
modified: combox/file.py
modified: tests/file_test.py
|
|
|
|
|
|
|
|
| |
modified: tests/config_test.py
modified: tests/crypto_test.py
modified: tests/events_test.py
modified: tests/file_test.py
modified: tests/silo_test.py
|
|
|
|
|
| |
rm_configdir() will be used to remove the test-config/ directory and
will be called in all teardown methods of Test classes.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
tests/shard-dir-1) in the teardown method.
modified: tests/config_test.py
modified: tests/crypto_test.py
modified: tests/events_test.py
modified: tests/file_test.py
modified: tests/silo_test.py
deleted: tests/shard-dir-0/.foo
deleted: tests/shard-dir-1/.foo
|
|
|
|
|
| |
rm_nodedirs purges the node directories. This function will be used
later to remove the test node directories.
|
| |
|
| |
|
| |
|
|
|
|
| |
Now the test is in a Test class with proper setup and teardown methods.
|
| |
|