docstr: Check that call() args and return annotations give input/output keys.
  
  Args:
    layer_class: Which type of class definition to use for test_layer.
docstr_tok: ["Check","that","call","(",")","args","and","return","annotations","give","input\/output","keys",".","Args",":","layer_class",":","Which","type","of","class","definition","to","use","for","test_layer","."]
code: def test_output_is_correct(self, layer_class):
      """Check that call() args and return annotations give input/output keys.
  
      Args:
        layer_class: Which type of class definition to use for test_layer.
      """
      test_layer = getattr(self, layer_class)()
      # Arg inputs.
      outputs = test_layer(self.x, self.x)
      self.assert_output_shapes_are_correct(test_layer, outputs)
  
      # Dict inputs.
      outputs = test_layer({"x1": self.x, "x2": self.x})
      self.assert_output_shapes_are_correct(test_layer, outputs)
  
      # Kwarg inputs.
      outputs = test_layer(x1=self.x, x2=self.x)
      self.assert_output_shapes_are_correct(test_layer, outputs)
  
      # Merge multiple dict inputs, ignore extra keys.
      outputs = test_layer(
          {"x1": self.x, "ignore": 0}, {"x2": self.x, "ignore2": 0}
      )
      self.assert_output_shapes_are_correct(test_layer, outputs)
  
      # Raises errors for bad inputs.
      # Wrong number of args.
      with self.assertRaises(TypeError):
          test_layer(self.x)
      # Missing key --> Wrong number of args.
      with self.assertRaises(TypeError):
          test_layer({"x1": self.x})
      # Missing key, wrong key name --> Wrong number of args.
      with self.assertRaises(TypeError):
          test_layer({"asdf": self.x, "x2": self.x})
      # Duplicate input argument.
      with self.assertRaises(TypeError):
          test_layer(self.x, {"x1": self.x, "x2": self.x})
  
imports: from absl.testing import parameterized
  from ddsp.training import nn
  import numpy
  import tensorflow.compat.v2
label_desc: Use image node_id 3 for calling the DictLayerTest obj's underlying member method code with example usage: obj.test_output_is_correct(layer_class) without return types