code: def testSingleKeySingleReal(self):
      testFile = "foo: 1.0"
      writeFile(testFile, "testfile")
  
      p = YamlInput(filename="testfile")()
      os.remove("testfile")
  
      self.assertAlmostEqual(p["foo"], 1.0)
  
      testJson = '{ "foo": 1.0 }'
      writeFile(testJson, "testfile")
  
      p = YamlInput(filename="testfile", format="json")()
      os.remove("testfile")
  
      self.assertAlmostEqual(p["foo"], 1.0)
  
imports: from essentia_test import *
  import os
label_desc: Use image node_id 1 for calling the TestYamlInput obj's underlying member method code with example usage: obj.testSingleKeySingleReal() without return types