Posts

Showing posts from July, 2019

Writing tests for Rust HTTP source | GSoC 2019

Image
Writing test is an important part of Plugin development in GStreamer or rather for all most all software development. There are several reasons which clearly tells us as why writing test cases are important. To point out the defects and errors that were made during the development phases To check whether all features are working at every change To figure out unhandled scenarios in our software My GSoC mentor, Sebastian Dröge coded the skeleton of the test with a basic unit test case for HTTP source plugin (aka  reqwesthttpsrc ). Here is the link to the merge request . The test was to check whether we receive the data correctly which is sent by the server. Here we make a hyper HTTP server which respond with "Hello World". Then we use our plugin to receive the data and we compare both. Also the interesting thing here is the Custom test harness which can be used to initialize a HTTP server with required behavior and our HTTP element with required properties set. We