TST: added tests for to_json when called on complex data (GH41174)
- [x] closes #41174
- [x] tests added / passed
- [x] Ensure all linting tests pass, see [here](https://pandas.pydata.org/pandas-docs/dev/development/contributing.html#code-standards) for how to run them

Provided tests for `to_json` when called on complex data on both `Series` and `DataFrame`. Coefficients are both `int` and `float`.

Tests and linter pass locally.
