Example #1
0
def test_query_with_array_of_struct(capsys, instance_id, sample_database):
    snippets.query_with_array_of_struct(instance_id,
                                        sample_database.database_id)
    out, _ = capsys.readouterr()
    assert "SingerId: 8" in out
    assert "SingerId: 7" in out
    assert "SingerId: 6" in out
Example #2
0
    def _():
        snippets.write_struct_data(
            SPANNER_INSTANCE,
            temporary_database.database_id)
        snippets.query_with_array_of_struct(
            SPANNER_INSTANCE,
            temporary_database.database_id)
        out, _ = capsys.readouterr()

        assert 'SingerId: 6\nSingerId: 7' in out
    def _():
        snippets.write_struct_data(
            SPANNER_INSTANCE,
            temporary_database.database_id)
        snippets.query_with_array_of_struct(
            SPANNER_INSTANCE,
            temporary_database.database_id)
        out, _ = capsys.readouterr()

        assert 'SingerId: 6\nSingerId: 7' in out
Example #4
0
def test_query_with_array_of_struct(capsys):
    snippets.query_with_array_of_struct(INSTANCE_ID, DATABASE_ID)
    out, _ = capsys.readouterr()
    assert 'SingerId: 8' in out
    assert 'SingerId: 7' in out
    assert 'SingerId: 6' in out
def test_query_with_array_of_struct(capsys):
    snippets.query_with_array_of_struct(INSTANCE_ID, DATABASE_ID)
    out, _ = capsys.readouterr()
    assert 'SingerId: 6\nSingerId: 7' in out