On Wed, 4 Dec 2019 at 07:44, Avi Kessner <akessner@...> wrote:
So this is definitely required behavior and it will be your own, so it needs to be tested.
On the other hand, it's a very specific implementation detail which could change when the technology changes and we don't want that to impact actual behavior related tests about animals.
What I would do is make a transformation decorator and then test sample data to see that it gets transformed correctly.? If Ecto ever changes, that transformation decorator can do nothing if needed.
You basically need a map of fields that can be changed and the transformation needed for that field.
A bit more work, but it allows for a change in Ecto or a change in understanding of Ecto to not impact the main test suite.
On Wed, Dec 4, 2019, 01:50 Brian Marick <marick@...> wrote:
Yes.
On Dec 3, 2019, at 5:31 AM, Avi Kessner <akessner@...> wrote:
If I understand correctly, the code here is specifically?for doing an Ecto transformation, correct? If you decide not to use Ecto the need for this abstraction is removed?