From 8538d2a2e6398ca122918469b18c98bc79ce93cf Mon Sep 17 00:00:00 2001 From: rreiner-hqs Date: Tue, 26 Nov 2024 11:55:35 +0100 Subject: [PATCH] add supported version test for new pragma --- .../operations/supported_version.rs | 27 ++----------------- 1 file changed, 2 insertions(+), 25 deletions(-) diff --git a/roqoqo/tests/integration/operations/supported_version.rs b/roqoqo/tests/integration/operations/supported_version.rs index 1de9ba28..172fa918 100644 --- a/roqoqo/tests/integration/operations/supported_version.rs +++ b/roqoqo/tests/integration/operations/supported_version.rs @@ -392,30 +392,7 @@ fn test_version_1_16_0_four_qubit_gate(operation: operations::FourQubitGateOpera assert_eq!(operation.minimum_supported_roqoqo_version(), (1, 16, 0)); } -#[test_case(operations::SingleQubitGateOperation::from(operations::InvTGate::new(0)); "SqrtPaInvTGateuliY")] -#[test_case(operations::SingleQubitGateOperation::from(operations::InvSGate::new(0)); "InvSGate")] -#[test_case(operations::SingleQubitGateOperation::from(operations::SXGate::new(0)); "SXGate")] -#[test_case(operations::SingleQubitGateOperation::from(operations::InvSXGate::new(0)); "InvSXGate")] -fn test_version_1_17_0_single_qubit_gate(operation: operations::SingleQubitGateOperation) { - assert_eq!(operation.minimum_supported_roqoqo_version(), (1, 17, 0)); -} - -#[test_case(operations::ThreeQubitGateOperation::from(operations::ControlledSWAP::new(0, 1, 2)); "ControlledSWAP")] -#[test_case(operations::ThreeQubitGateOperation::from(operations::PhaseShiftedControlledControlledZ::new(0, 1, 2, CalculatorFloat::PI)); "PhaseShiftedControlledControlledZ")] -#[test_case(operations::ThreeQubitGateOperation::from(operations::PhaseShiftedControlledControlledPhase::new(0, 1, 2, CalculatorFloat::PI, CalculatorFloat::PI)); "PhaseShiftedControlledControlledPhase")] -fn test_version_1_17_0_three_qubit_gate(operation: operations::ThreeQubitGateOperation) { - assert_eq!(operation.minimum_supported_roqoqo_version(), (1, 17, 0)); -} - -#[test_case( - operations::FourQubitGateOperation::from(operations::TripleControlledPauliX::new(0, 1, 2, 3)); "TripleControlledPauliX" -)] -#[test_case( - operations::FourQubitGateOperation::from(operations::TripleControlledPauliZ::new(0, 1, 2, 3)); "TripleControlledPauliZ" -)] -#[test_case( - operations::FourQubitGateOperation::from(operations::TripleControlledPhaseShift::new(0, 1, 2, 3, CalculatorFloat::PI)); "TripleControlledPhaseShift" -)] -fn test_version_1_17_0_four_qubit_gate(operation: operations::FourQubitGateOperation) { +#[test_case(operations::Operation::from(operations::PragmaSimulationRepetitions::new(100)))] +fn test_version_1_17_0_pragmas(operation: operations::Operation) { assert_eq!(operation.minimum_supported_roqoqo_version(), (1, 17, 0)); }