From df47d03c46c4a41325f2baa5762e6e9c7586d595 Mon Sep 17 00:00:00 2001 From: Matt Beach Date: Tue, 16 Apr 2024 13:14:11 -0400 Subject: [PATCH] fix: tests --- .../tasks/analog_hamiltonian_simulation_quantum_task_result.py | 2 +- test/unit_tests/braket/registers/test_qubit.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/braket/tasks/analog_hamiltonian_simulation_quantum_task_result.py b/src/braket/tasks/analog_hamiltonian_simulation_quantum_task_result.py index dd6bcecde..7bfb57eb3 100644 --- a/src/braket/tasks/analog_hamiltonian_simulation_quantum_task_result.py +++ b/src/braket/tasks/analog_hamiltonian_simulation_quantum_task_result.py @@ -129,7 +129,7 @@ def get_counts(self) -> dict[str, int]: 0 if pre_i == 0 else 1 if post_i == 0 else 2 for pre_i, post_i in zip(pre, post) ] state = "".join(states[s_idx] for s_idx in state_idx) - state_counts |= (state,) + state_counts.update([state]) return dict(state_counts) diff --git a/test/unit_tests/braket/registers/test_qubit.py b/test/unit_tests/braket/registers/test_qubit.py index 5927cf197..0c04a5d95 100644 --- a/test/unit_tests/braket/registers/test_qubit.py +++ b/test/unit_tests/braket/registers/test_qubit.py @@ -54,4 +54,4 @@ def test_new_with_int(): qubit = 0 qubit_new = Qubit.new(qubit) assert qubit_new == qubit - assert qubit_new != qubit + assert qubit_new is not qubit