def METHOD_NAME():
    circuit = construct_small_circuit()
    device_graph = cirq.testing.construct_grid_device(7, 7).metadata.nx_graph
    mapper = cirq.LineInitialMapper(device_graph)
    mapping = mapper.initial_mapping(circuit)
    assert mapper.center == cirq.GridQubit(3, 3)
    expected_circuit = cirq.Circuit(
        [
            cirq.Moment(cirq.CNOT(cirq.GridQubit(1, 3), cirq.GridQubit(2, 3))),
            cirq.Moment(cirq.CNOT(cirq.GridQubit(3, 3), cirq.GridQubit(2, 3))),
            cirq.Moment(
                cirq.CNOT(cirq.GridQubit(2, 2), cirq.GridQubit(2, 3)), cirq.X(cirq.GridQubit(3, 2))
            ),
        ]
    )
    cirq.testing.assert_same_circuits(circuit.transform_qubits(mapping), expected_circuit)