Skip to content
This repository has been archived by the owner on Aug 21, 2024. It is now read-only.

Commit

Permalink
Switched to a new dump functionality exposed by QuantumSimulator (#727)
Browse files Browse the repository at this point in the history
  • Loading branch information
kuzminrobin authored Jan 14, 2022
1 parent 2b68127 commit 4c92000
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions utilities/Microsoft.Quantum.Katas/KataMagic.cs
Original file line number Diff line number Diff line change
Expand Up @@ -169,10 +169,11 @@ public virtual bool Simulate(OperationInfo test, OperationInfo userAnswer, IChan

try
{
var qsim = CreateSimulator(channel);
var qsim = CreateSimulator();

qsim.DisableExceptionPrinting();
qsim.DisableLogToConsole();
qsim.OnLog += channel.Stdout;

qsim.OnDisplayableDiagnostic += channel.Display;

Expand Down Expand Up @@ -206,8 +207,8 @@ public virtual bool Simulate(OperationInfo test, OperationInfo userAnswer, IChan
/// Creates the instance of the simulator to use to run the Test
/// (for now always CounterSimulator from the same package).
/// </summary>
public virtual SimulatorBase CreateSimulator(IChannel channel) =>
new CounterSimulator().WithJupyterDisplay(channel, ConfigurationSource);
public virtual SimulatorBase CreateSimulator() =>
new CounterSimulator();

/// <summary>
/// Returns the OperationInfo with the Test to run based on the given name.
Expand Down

0 comments on commit 4c92000

Please sign in to comment.