Open
Bug 1436014
Opened 7 years ago
Updated 7 years ago
Create explicit unit-tests for in_changeset
Categories
(Localization Infrastructure and Tools :: Fluent Migration, enhancement)
Localization Infrastructure and Tools
Fluent Migration
Tracking
(Not tracked)
NEW
People
(Reporter: Pike, Unassigned)
Details
Right now, the behavior of the internal function `in_changeset` in `MergeContext.merge_changeset` is done via testing the `merge_changeset` method.
I wonder if we can make the code a bit easier to read and to test if we'd move in_changeset to MergeContext, and used https://docs.python.org/2/library/functools.html#functools.partial to bind it to a path.
Then we could explicitly just test its own behaviour, and that'd make a bunch of tests a lot smaller, and probably easier to verify, too.
Comment 1•7 years ago
|
||
Thanks for filing this. I had a similar though. I bothers me that in_changeset, despite its small size, has such an important role. I'll be happy to refactor this and have more tests!
Updated•7 years ago
|
Blocks: fluent.migrate
Updated•7 years ago
|
No longer blocks: fluent.migrate
Component: Python Library → Fluent Migration
Product: L20n → Localization Infrastructure and Tools
Reporter | ||
Comment 3•7 years ago
|
||
https://hg.mozilla.org/l10n/fluent-migration/rev/e3791d22c931 laid the foundation here.
https://hg.mozilla.org/l10n/fluent-migration/rev/cb364e72d8d5 started the first couple of tests.
To actually fix this, we'll need to extend the real test coverage, and maybe also consider to remove obsolete merge_changeset tests. Unless we want to keep 'em as integration tests.
I don't have work lined up for this right now, so unassigning myself.
Assignee: l10n → nobody
You need to log in
before you can comment on or make changes to this bug.
Description
•