test/libcephfs: close fd after creating file

Fixes: #6742
Signed-off-by: Yan, Zheng <zheng.z.yan@intel.com>