The application in question is the KTX loader (https://github.com/KhronosGroup/KTX). KTX supports any format so in order to use the approach you suggest I would have to maintain a large table of format enums to extension names. It couldn’t even be a simple table because the enum values aren’t packed together. So there would be some inelegant code.
The IMG emulator is the first implementation I have encountered that does not raise an error. The only issue I previously encountered was an implementation that raised INVALID_VALUE instead of INVALID_ENUM.
You can use the KTX es1loadtests to reproduce the problem. Clone the repo from the above URL and checkout the “incoming” branch. Install GYP as per the KTX README. Edit the file gyp_include/config.gypi in the KTX source, commenting out maliemu.gypi in the includes at the bottom and uncommenting pvremu.gypi. Then regenerate the projects (“make msvs”) and open the generated solution (build/msvs/vsNNNN) in your version of Visual Studio (NNNN is, e.g, 2013) and build and run es1loadtests.
All the ETC2 tests will show a yellow square due to this bug. The loader has a software ETC2 decoder that it uses when a raised error indicates the implementation does not support the formats. In that case you will see some images.