code: def test_serialization(base_layer, rnn):
      base_layer = base_layer()
      wn_layer = wrappers.WeightNormalization(base_layer, not rnn)
      new_wn_layer = tf.keras.layers.deserialize(
          tf.keras.layers.serialize(wn_layer)
      )
      assert wn_layer.data_init == new_wn_layer.data_init
      assert wn_layer.is_rnn == new_wn_layer.is_rnn
      assert wn_layer.is_rnn == rnn
      if not isinstance(base_layer, tf.keras.layers.LSTM):
          # Issue with LSTM serialization, check with TF-core
          # Before serialization: tensorflow.python.keras.layers.recurrent_v2.LSTM
          # After serialization: tensorflow.python.keras.layers.recurrent.LSTM
          assert isinstance(new_wn_layer.layer, base_layer.__class__)
  
file_path: addons/tensorflow_addons/layers/tests/wrappers_test.py
imports: import os
  import tempfile
  import pytest
  import numpy
  import tensorflow
  from tensorflow_addons.layers import wrappers
  from tensorflow_addons.utils import test_utils
label_desc: Use image node_id 9 for calling a global function with example usage: test_serialization(base_layer, rnn) without return types