code: def test_zerosized_matrix_arg(self):
      # test for gh-4908: check the shape of the result for
      # zero-sized matrix inputs, i.e. matrices with shape (0,n) or (n,0).
      # note that [[]] takes shape (1,0)
      a = block_diag(
          [[1, 0], [0, 1]],
          [[]],
          [[2, 3], [4, 5], [6, 7]],
          np.zeros([0, 2], dtype="int32"),
      )
      assert_array_equal(
          a,
          [
              [1, 0, 0, 0, 0, 0],
              [0, 1, 0, 0, 0, 0],
              [0, 0, 0, 0, 0, 0],
              [0, 0, 2, 3, 0, 0],
              [0, 0, 4, 5, 0, 0],
              [0, 0, 6, 7, 0, 0],
          ],
      )
  
imports: import pytest
  import numpy
  from numpy import arange, array, eye, copy, sqrt
  from numpy.testing import assert_equal, assert_array_equal, assert_array_almost_equal, assert_allclose
  from pytest import raises
  from scipy.fft import fft
  from scipy.special import comb
  from scipy.linalg import toeplitz, hankel, circulant, hadamard, leslie, dft, companion, kron, block_diag, helmert, hilbert, invhilbert, pascal, invpascal, fiedler, fiedler_companion, eigvals, convolution_matrix
  from numpy.linalg import cond
label_desc: Use image node_id 8 for calling the TestBlockDiag obj's underlying member method code with example usage: obj.test_zerosized_matrix_arg() without return types