Add dim test for rings over integers

Hello,


I added a test for diim() for rings over integers.
Not sure if all important cases are covered, but it is better than nothing.
The test is passed by spielwiese, master branch and v3.1.6.



Best,