Couldn't think of a good way to describe the issue in a short title, but here's the breakdown. I have a change set I'm trying to deploy from sandbox. The change set contains 2 classes and a VF page. When deploying I'm running a specified test class. This test class is giving between 80% and 90% coverage on the larger of the classes in the change set.
The other class in the change set is not being covered by that test class, however it's only 7 lines, so it should not be pulling the average down below 75% across the whole change set. When I try to deploy, I get this error:
Your code coverage is 0%. You need at least 75% coverage to complete this deployment.
With just the one (uncovered) class's name underneath. Far as I knew, the code coverage is looking for an average across classes, correct? Not each individual class? And note, this is a class, NOT a trigger. I am aware that triggers need at least 1%.
Why does the validation seem to only consider the one class's coverage? Is it because the second class already exists, and doesn't have major changes? I even tried including the test class in the change set to no avail.
The other really bizarre thing is that if I choose 'Default' for the tests to run for this change set it doesn't actually run any tests, which I find very strange...