hudl / HudlFfmpeg

Hudl.Ffmpeg framework
Apache License 2.0
112 stars 32 forks source link

MetadataInfo class is not testable #76

Open developerdizzle opened 7 years ago

developerdizzle commented 7 years ago

While attempting to write some unit tests in another project, I came across the need to construct a MetadataInfo object. Unfortunately, its constructor is private and its Create methods are internal.

Ideally, I would like to be able to mock this class like any other "dumb" model. My larger goal here is to mock VideoStream and AudioStream objects that have particular metadata properties, that I can use in unit tests for methods that perform sanity checks against these streams.

I could certainly submit a PR to make the constructor and Create properties more accessible, but I'm not sure that's the best approach here, and was hoping to start some discussion around it.