def METHOD_NAME(flex):
    for name in flex.grid["node"]:
        field = flex.grid["node"][name]
        assert isinstance(field, np.ndarray)
        assert field.shape == (
            flex.grid.number_of_node_rows * flex.grid.number_of_node_columns,
        )
    with pytest.raises(KeyError):
        flex.grid["not_a_var_name"]