In a new project, a friend had to write tests where the time required to write them was calculated by an Excel macro written by his non-developer manager.
There are parametric estimation models for estimating completion time of projects, including software projects. Usually, the estimate is for production code, but I don't see why it can't be extrapolated to estimate how long it will take to write test code. These estimates are only as good as the data that is fed into them, though.
Assuming that the method used is a valid estimation model and the data is accurate and valid, there's no reason why a good estimate can't come from an Excel macro written by a non-developer manager.
In such circumstances, should a developer accept the responsibility to write and run the tests in the calculated time?
No estimate should ever be blindly accepted, under any circumstances. No estimate is ever perfect, regardless of how it is generated. It's up to the engineer to review any estimates, identify potential problems, assess their impact, and discuss and refine the estimate as needed.
Are the results of these test trustworthy?
Tests are only as good as the effort spent in designing and implementing them. If a tester produces low-quality tests, defects will slip through testing and make it to a later phase of the project. It stands to reason that schedule pressure will lead to low-quality tests, so if the time is insufficient to design the appropriate test cases and then implement those cases, then the tests would not be as useful.