Conversely, adding lines of code but NOT adding functionality isn't worth a cent.
The "code as liability" argument seems, unless I'm mistaken, to be based on the idea that less code for the same level of functionality means less cruft, and therefore better support for the NFRs that I mentioned above.
That's often true, but not always.
If you're including those NFRs in what you mean by same functionality, then the number of lines of code is utterly irrelevant.
The market value for code without valuable functionality is negative.
[1] Value as determined by how much anyone is willing to pay to use the software.
Tests can provide a number of things: they can serve as API examples, assure functionality, speed up implementing new functionality and debugging.
If you tests don't do these things, they are not worth keeping, either.