add file descriptor close safely in test
add file descriptor close safely in test

Signed-off-by: Cosrider <f1dcb883c901b6d856614e79151301dcadd3639e@gmail.com>

prometheus/node_exporter,prometheus/node_exporter,prometheus/node_exporter