Closed petervdonovan closed 1 year ago
thanks for creating this @petervdonovan! i tried to run the syntax test locally, and it finished quickly as you reported (: however, some of the tests are failing, even though i haven't applied any changes. any idea why this could be happening?
from what i can gather from the terminal output, it looks like there's some mismatch in the HTML for C/src/ArrayFree.lf
, but i think it would be helpful to add the filename in the AssertionError output. there's also a new failing
directory under C/src/arduino
that contains all of the arduino tests, so i assume all of those don't match the "known good" files as well.
It sounds like you may have checked out a different lingua-franca
submodule from the one that is tracked in this branch. If you execute git submodule update --init
, and rerun the test, does it pass?
Anyway, it is not so important that this test passes right now because maybe we will update the lingua-franca
submodule soon, at which point it will fail again.
Here is an example:
~/vscode-lingua-franca$ !npm
npm run test-syntax
> vscode-lingua-franca@0.4.1 test-syntax
> npm run compile-tests && npx mocha out/test/test/check_highlighting.test.js --ui tdd --reporter-option maxDiffSize=0
> vscode-lingua-franca@0.4.1 compile-tests
> npx tsc --lib "dom" --outDir out/test --inlineSourceMap
test syntax highlighting
checking ActionDelay.txt... ✓
checking ActionIsPresent.txt... ✓
checking ActionWithNoReaction.txt... ✓
checking After.txt... ✓
checking AfterCycles.txt... ✓
checking AfterOverlapped.txt... ✓
checking AfterZero.txt... ✓
checking Alignment.txt... ✓
checking AnalogReadSerial.txt... ✓
checking Blink.txt... ✓
checking BlinkAttemptThreading.txt... ✓
checking BlinkMBED.txt... ✓
checking DigitalReadSerial.txt... ✓
checking Fade.txt... ✓
checking ReadAnalogVoltage.txt... ✓
checking ArrayAsParameter.txt... ✓
checking ArrayAsType.txt... ✓
checking ArrayFree.txt... ✓
checking ArrayFreeMultiple.txt... ✓
checking ArrayParallel.txt... ✓
checking ArrayPrint.txt... ✓
checking ArrayScale.txt... ✓
checking CharLiteralInitializer.txt... ✓
checking Composition.txt... ✓
checking CompositionAfter.txt... ✓
checking CompositionGain.txt... ✓
checking CompositionInheritance.txt... ✓
checking AsyncCallback.txt... ✓
checking AsyncCallbackDrop.txt... ✓
checking AsyncCallbackReplace.txt... ✓
checking CompositionThreaded.txt... ✓
checking DeadlineHandledAboveThreaded.txt... ✓
checking DeadlineThreaded.txt... ✓
checking DelayIntThreaded.txt... ✓
checking DeterminismThreaded.txt... ✓
checking DoubleReactionThreaded.txt... ✓
checking GainThreaded.txt... ✓
checking HelloThreaded.txt... ✓
checking ImportThreaded.txt... ✓
checking MinimalThreaded.txt... ✓
checking PingPongThreaded.txt... ✓
checking ScheduleAt.txt... ✓
checking ScheduleTwice.txt... ✓
checking ScheduleTwiceThreaded.txt... ✓
checking SendingInsideThreaded.txt... ✓
checking StarvationThreaded.txt... ✓
checking StopThreaded.txt... ✓
checking StopZeroThreaded.txt... ✓
checking Threaded.txt... ✓
checking ThreadedMultiport.txt... ✓
checking ThreadedThreaded.txt... ✓
checking TimeLimitThreaded.txt... ✓
checking TimeoutThreaded.txt... ✓
checking TimeoutZeroThreaded.txt... ✓
checking Tracing.txt... ✓
checking Workers.txt... ✓
checking CountSelf.txt... ✓
checking CountTest.txt... ✓
checking DanglingOutput.txt... ✓
checking Deadline.txt... ✓
checking DeadlineAnytime.txt... ✓
checking DeadlineHandledAbove.txt... ✓
checking DeadlineInherited.txt... ✓
checking DeadlinePriority.txt... ✓
checking DeadlineWithAfterDelay.txt... ✓
checking DeadlineWithBanks.txt... ✓
checking DeadlineZero.txt... ✓
checking DelayArray.txt... ✓
checking DelayArrayWithAfter.txt... ✓
checking DelayedAction.txt... ✓
checking DelayedReaction.txt... ✓
checking DelayInt.txt... ✓
checking DelayPointer.txt... ✓
checking DelayString.txt... ✓
checking DelayStruct.txt... ✓
checking DelayStructWithAfter.txt... ✓
checking DelayStructWithAfterOverlapped.txt... ✓
checking Determinism.txt... ✓
checking DistributedCountContainerized.txt... ✓
checking DistributedDoublePortContainerized.txt... ✓
checking DistributedMultiportContainerized.txt... ✓
checking DistributedStopDecentralizedContainerized.txt... ✓
checking FilesPropertyContainerized.txt... ✓
checking HelloWorldContainerized.txt... ✓
checking PingPongContainerized.txt... ✓
checking DoubleInvocation.txt... ✓
checking DoublePort.txt... ✓
checking DoubleReaction.txt... ✓
checking DoubleTrigger.txt... ✓
checking BroadcastFeedback.txt... ✓
checking BroadcastFeedbackWithHierarchy.txt... ✓
checking ChainWithDelay.txt... ✓
checking CycleDetection.txt... ✓
checking DecentralizedP2PComm.txt... ✓
checking DecentralizedP2PUnbalancedTimeout.txt... ✓
checking DecentralizedP2PUnbalancedTimeoutPhysical.txt... ✓
checking DistributedBank.txt... ✓
checking DistributedBankToMultiport.txt... ✓
checking DistributedCount.txt... ✓
checking DistributedCountDecentralized.txt... ✓
checking DistributedCountDecentralizedLate.txt... ✓
checking DistributedCountDecentralizedLateHierarchy.txt... ✓
checking DistributedCountPhysical.txt... ✓
checking DistributedCountPhysicalAfterDelay.txt... ✓
checking DistributedCountPhysicalDecentralized.txt... ✓
checking DistributedDoublePort.txt... ✓
checking DistributedLogicalActionUpstreamLong.txt... ✓
checking DistributedLoopedAction.txt... ✓
checking DistributedLoopedActionDecentralized.txt... ✓
checking DistributedLoopedPhysicalAction.txt... ✓
checking DistributedLoopedPhysicalActionDecentralized.txt... ✓
checking DistributedMultiport.txt... ✓
checking DistributedMultiportToBank.txt... ✓
checking DistributedMultiportToken.txt... ✓
checking DistributedNetworkOrder.txt... ✓
checking DistributedPhysicalActionUpstream.txt... ✓
checking DistributedPhysicalActionUpstreamLong.txt... ✓
checking DistributedStop.txt... ✓
checking DistributedStopDecentralized.txt... ✓
checking DistributedStopZero.txt... ✓
checking DistributedStopZeroDecentralized.txt... ✓
checking DistributedToken.txt... ✓
checking ClockSync.txt... ✓
checking DistributedDoublePortLooped.txt... ✓
checking DistributedDoublePortLooped2.txt... ✓
checking DistributedNetworkOrderDecentralized.txt... ✓
checking LoopDistributedDecentralizedPrecedence.txt... ✓
checking LoopDistributedDecentralizedPrecedenceHierarchy.txt... ✓
checking FeedbackDelay.txt... ✓
checking FeedbackDelaySimple.txt... ✓
checking HelloDistributed.txt... ✓
checking LoopDistributedCentralized.txt... ✓
checking LoopDistributedCentralized2.txt... ✓
checking LoopDistributedCentralizedPhysicalAction.txt... ✓
checking LoopDistributedCentralizedPrecedence.txt... ✓
checking LoopDistributedCentralizedPrecedenceHierarchy.txt... ✓
checking LoopDistributedDecentralized.txt... ✓
checking LoopDistributedDouble.txt... ✓
checking ParallelDestinations.txt... ✓
checking ParallelSources.txt... ✓
checking ParallelSourcesMultiport.txt... ✓
checking PhysicalSTP.txt... ✓
checking PingPongDistributed.txt... ✓
checking PingPongDistributedPhysical.txt... ✓
checking SimpleFederated.txt... ✓
checking SimpleFederatedAuthenticated.txt... ✓
checking StopAtShutdown.txt... ✓
checking TopLevelArtifacts.txt... ✓
checking FloatLiteral.txt... ✓
checking Gain.txt... ✓
checking GetMicroStep.txt... ✓
checking GetTime.txt... ✓
checking Hello.txt... ✓
checking HelloWorld.txt... ✓
checking Hierarchy.txt... ✓
checking Hierarchy2.txt... ✓
checking IdentifierLength.txt... ✓
checking Import.txt... ✓
checking ImportComposition.txt... ✓
checking ImportRenamed.txt... ✓
checking InheritanceAction.txt... ✓
checking Count.txt... ✓
checking Imported.txt... ✓
checking ImportedAgain.txt... ✓
checking ImportedComposition.txt... ✓
checking InternalDelay.txt... ✓
checking LoopedActionSender.txt... ✓
checking PassThrough.txt... ✓
checking Test.txt... ✓
checking TestCount.txt... ✓
checking TestCountMultiport.txt... ✓
checking ManualDelayedReaction.txt... ✓
checking Methods.txt... ✓
checking MethodsRecursive.txt... ✓
checking MethodsSameName.txt... ✓
checking Microsteps.txt... ✓
checking Minimal.txt... ✓
checking BanksCount3ModesComplex.txt... ✓
checking BanksCount3ModesSimple.txt... ✓
checking BanksModalStateReset.txt... ✓
checking ConvertCaseTest.txt... ✓
checking Count3Modes.txt... ✓
checking MixedReactions.txt... ✓
checking ModalActions.txt... ✓
checking ModalAfter.txt... ✓
checking ModalCycleBreaker.txt... ✓
checking ModalNestedReactions.txt... ✓
checking ModalStartupShutdown.txt... ✓
checking ModalStateReset.txt... ✓
checking ModalStateResetAuto.txt... ✓
checking ModalTimers.txt... ✓
checking MultipleOutputFeeder_2Connections.txt... ✓
checking MultipleOutputFeeder_ReactionConnections.txt... ✓
checking TraceTesting.txt... ✓
checking MovingAverage.txt... ✓
checking MultipleContained.txt... ✓
checking MultipleOutputs.txt... ✓
checking BankGangedConnections.txt... ✓
checking BankIndexInitializer.txt... ✓
checking BankMulticast.txt... ✓
checking BankMultiportToReaction.txt... ✓
checking BankReactionsInContainer.txt... ✓
checking BankSelfBroadcast.txt... ✓
checking BankToBank.txt... ✓
checking BankToBankMultiport.txt... ✓
checking BankToBankMultiportAfter.txt... ✓
checking BankToMultiport.txt... ✓
checking BankToReaction.txt... ✓
checking Broadcast.txt... ✓
checking BroadcastAfter.txt... ✓
checking BroadcastMultipleAfter.txt... ✓
checking DualBanks.txt... ✓
checking DualBanksMultiport.txt... ✓
checking FullyConnected.txt... ✓
checking FullyConnectedAddressable.txt... ✓
checking FullyConnectedAddressableAfter.txt... ✓
checking MultiportFromBank.txt... ✓
checking MultiportFromBankHierarchy.txt... ✓
checking MultiportFromBankHierarchyAfter.txt... ✓
checking MultiportFromHierarchy.txt... ✓
checking MultiportFromReaction.txt... ✓
checking MultiportIn.txt... ✓
checking MultiportInParameterized.txt... ✓
checking MultiportMutableInput.txt... ✓
checking MultiportMutableInputArray.txt... ✓
checking MultiportOut.txt... ✓
checking MultiportToBank.txt... ✓
checking MultiportToBankAfter.txt... ✓
checking MultiportToBankDouble.txt... ✓
checking MultiportToBankHierarchy.txt... ✓
checking MultiportToHierarchy.txt... ✓
checking MultiportToMultiport.txt... ✓
checking MultiportToMultiport2.txt... ✓
checking MultiportToMultiport2After.txt... ✓
checking MultiportToMultiportArray.txt... ✓
checking MultiportToMultiportParameter.txt... ✓
checking MultiportToPort.txt... ✓
checking MultiportToReaction.txt... ✓
checking NestedBanks.txt... ✓
checking NestedInterleavedBanks.txt... ✓
checking PipelineAfter.txt... ✓
checking ReactionsToNested.txt... ✓
checking ReactionToContainedBank.txt... ✓
checking ReactionToContainedBank2.txt... ✓
checking ReactionToContainedBankMultiport.txt... ✓
checking Sparse.txt... ✓
checking SparseFallback.txt... ✓
checking TriggerDownstreamOnlyIfPresent.txt... ✓
checking NativeListsAndTimes.txt... ✓
checking NestedTriggeredReactions.txt... ✓
checking ParameterHierarchy.txt... ✓
checking ParameterizedState.txt... ✓
checking PeriodicDesugared.txt... ✓
checking PhysicalConnection.txt... ✓
checking PingPong.txt... ✓
checking Preamble.txt... ✓
checking ReadOutputOfContainedReactor.txt... ✓
checking RepeatedInheritance.txt... ✓
checking RequestStop.txt... ✓
checking Schedule.txt... ✓
checking ScheduleLogicalAction.txt... ✓
checking ScheduleValue.txt... ✓
checking SelfLoop.txt... ✓
checking SendingInside.txt... ✓
checking SendingInside2.txt... ✓
checking SendsPointerTest.txt... ✓
checking PersonProtocolBuffers.txt... ✓
checking ProtoNoPacking.txt... ✓
checking ROSBuiltInSerialization.txt... ✓
checking ROSBuiltInSerializationSharedPtr.txt... ✓
checking SetArray.txt... ✓
checking SetToken.txt... ✓
checking SimpleDeadline.txt... ✓
checking SimpleImport.txt... ✓
checking SlowingClock.txt... ✓
checking SlowingClockPhysical.txt... ✓
checking StartupOutFromInside.txt... ✓
checking Starvation.txt... ✓
checking Stop.txt... ✓
checking StopZero.txt... ✓
checking Stride.txt... ✓
checking StructAsState.txt... ✓
checking StructAsType.txt... ✓
checking StructAsTypeDirect.txt... ✓
checking StructParallel.txt... ✓
checking StructPrint.txt... ✓
checking StructScale.txt... ✓
checking SubclassesAndStartup.txt... ✓
checking CMakeInclude.txt... ✓
checking DistributedCMakeInclude.txt... ✓
checking DistributedCMakeIncludeSeparateCompile.txt... ✓
checking Files.txt... ✓
checking HelloWorldCCPP.txt... ✓
checking HelloWorldFederatedCCPP.txt... ✓
checking HelloWorldThreadedCPP.txt... ✓
checking ImportedCMakeInclude.txt... ✓
checking Platform.txt... ✓
checking TestForPreviousOutput.txt... ✓
checking TimeLimit.txt... ✓
checking Timeout.txt... ✓
checking TimeoutZero.txt... ✓
checking TimeState.txt... ✓
checking Token.txt... ✓
checking TokenContainedPrint.txt... ✓
checking TokenContainedPrintBank.txt... ✓
checking TokenContainedSource.txt... ✓
checking TokenContainedSourceBank.txt... ✓
checking TokenDelayTest.txt... ✓
checking TokenMutable.txt... ✓
checking TokenSourcePrint.txt... ✓
checking TokenSourceScalePrint.txt... ✓
checking ToReactionNested.txt... ✓
checking TriggerDownstreamOnlyIfPresent2.txt... ✓
checking UnconnectedInput.txt... ✓
checking Wcet.txt... ✓
checking Blinky2.txt... ✓
checking HelloZephyr.txt... ✓
checking Led.txt... ✓
checking Timer.txt... ✓
checking ActionDelay.txt... ✓
checking ActionIsPresent.txt... ✓
checking ActionValues.txt... ✓
checking ActionWithNoReaction.txt... ✓
checking After.txt... ✓
checking AfterOverlapped.txt... ✓
checking AfterZero.txt... ✓
checking Alignment.txt... ✓
checking ArrayAsParameter.txt... ✓
checking ArrayAsType.txt... ✓
checking ArrayParallel.txt... ✓
checking ArrayPrint.txt... ✓
checking ArrayScale.txt... ✓
checking CharLiteralInitializer.txt... ✓
checking Composition.txt... ✓
checking CompositionAfter.txt... ✓
checking CompositionGain.txt... ✓
checking AsyncCallback.txt... ✓
checking AsyncCallback2.txt... ✓
checking CompositionThreaded.txt... ✓
checking DeadlineHandledAboveThreaded.txt... ✓
checking DeadlineThreaded.txt... ✓
checking DelayIntThreaded.txt... ✓
checking DeterminismThreaded.txt... ✓
checking DoubleReactionThreaded.txt... ✓
checking GainThreaded.txt... ✓
checking HelloThreaded.txt... ✓
checking ImportThreaded.txt... ✓
checking MinimalThreaded.txt... ✓
checking SendingInsideThreaded.txt... ✓
checking Threaded.txt... ✓
checking ThreadedThreaded.txt... ✓
checking TimeLimitThreaded.txt... ✓
checking Workers.txt... ✓
checking CountTest.txt... ✓
checking DanglingOutput.txt... ✓
checking Deadline.txt... ✓
checking DeadlineHandledAbove.txt... ✓
checking DelayedAction.txt... ✓
checking DelayedReaction.txt... ✓
checking DelayInt.txt... ✓
checking Determinism.txt... ✓
checking DoubleInvocation.txt... ✓
checking DoublePort.txt... ✓
checking DoubleReaction.txt... ✓
checking DoubleTrigger.txt... ✓
checking EnclaveBank.txt... ✓
checking EnclaveBankEach.txt... ✓
checking EnclaveHelloWorld.txt... ✓
checking EnclaveHierarchy.txt... ✓
checking EnclaveShutdown.txt... ✓
checking EnclaveTimeout.txt... ✓
checking FastAndSlow.txt... ✓
checking FloatLiteral.txt... ✓
checking Gain.txt... ✓
checking GetMicroStep.txt... ✓
checking GetTime.txt... ✓
checking Hello.txt... ✓
checking HelloWorld.txt... ✓
checking Hierarchy.txt... ✓
checking Hierarchy2.txt... ✓
checking Import.txt... ✓
checking ImportComposition.txt... ✓
checking ImportRenamed.txt... ✓
checking Count.txt... ✓
checking Imported.txt... ✓
checking ImportedAgain.txt... ✓
checking ImportedComposition.txt... ✓
checking LoopedActionSender.txt... ✓
checking ManualDelayedReaction.txt... ✓
checking Methods.txt... ✓
checking Microsteps.txt... ✓
checking Minimal.txt... ✓
checking MovingAverage.txt... ✓
checking MultipleContained.txt... ✓
checking BankSelfBroadcast.txt... ✓
checking BankToBank.txt... ✓
checking BankToBankMultiport.txt... ✓
checking BankToBankMultiportAfter.txt... ✓
checking BankToMultiport.txt... ✓
checking Broadcast.txt... ✓
checking BroadcastAfter.txt... ✓
checking BroadcastMultipleAfter.txt... ✓
checking FullyConnected.txt... ✓
checking FullyConnectedAddressable.txt... ✓
checking FullyConnectedAddressableAfter.txt... ✓
checking IndexIntoMultiportInput.txt... ✓
checking IndexIntoMultiportOutput.txt... ✓
checking Multiport.txt... ✓
checking MultiportFromBank.txt... ✓
checking MultiportFromBankHierarchy.txt... ✓
checking MultiportFromBankHierarchyAfter.txt... ✓
checking MultiportFromHierarchy.txt... ✓
checking MultiportIn.txt... ✓
checking MultiportMultipleSet.txt... ✓
checking MultiportOut.txt... ✓
checking MultiportToBank.txt... ✓
checking MultiportToBankAfter.txt... ✓
checking MultiportToBankHierarchy.txt... ✓
checking MultiportToHierarchy.txt... ✓
checking MultiportToMultiport.txt... ✓
checking MultiportToMultiport2.txt... ✓
checking MultiportToMultiport2After.txt... ✓
checking MultiportToMultiportArray.txt... ✓
checking MultiportToMultiportPhysical.txt... ✓
checking MultiportToPort.txt... ✓
checking PipelineAfter.txt... ✓
checking ReadMultiportOutputOfContainedBank.txt... ✓
checking ReadOutputOfContainedBank.txt... ✓
checking SparseMultiport.txt... ✓
checking WidthGivenByCode.txt... ✓
checking WriteInputOfContainedBank.txt... ✓
checking WriteMultiportInputOfContainedBank.txt... ✓
checking NativeListsAndTimes.txt... ✓
checking NestedTriggeredReactions.txt... ✓
checking ParameterHierarchy.txt... ✓
checking ParameterizedState.txt... ✓
checking ParametersOutOfOrder.txt... ✓
checking PeriodicDesugared.txt... ✓
checking PhysicalConnection.txt... ✓
checking Pipeline.txt... ✓
checking PreambleTest.txt... ✓
checking Fast.txt... ✓
checking Keepalive.txt... ✓
checking Timeout.txt... ✓
checking TimeoutZero.txt... ✓
checking ReadOutputOfContainedReactor.txt... ✓
checking Schedule.txt... ✓
checking ScheduleLogicalAction.txt... ✓
checking SelfLoop.txt... ✓
checking SendingInside.txt... ✓
checking SendingInside2.txt... ✓
checking SimpleDeadline.txt... ✓
checking SimpleImport.txt... ✓
checking SlowingClock.txt... ✓
checking SlowingClockPhysical.txt... ✓
checking StartupOutFromInside.txt... ✓
checking Stride.txt... ✓
checking StructAsState.txt... ✓
checking StructAsType.txt... ✓
checking StructAsTypeDirect.txt... ✓
checking StructParallel.txt... ✓
checking StructPrint.txt... ✓
checking StructScale.txt... ✓
checking AfterVoid.txt... ✓
checking BraceAndParenInitialization.txt... ✓
checking CliParserGenericArguments.txt... ✓
checking CMakeInclude.txt... ✓
checking CombinedTypeNames.txt... ✓
checking GenericAfter.txt... ✓
checking GenericDelay.txt... ✓
checking GenericParameterAndState.txt... ✓
checking MultipleContainedGeneric.txt... ✓
checking PointerParameters.txt... ✓
checking PreambleFile.txt... ✓
checking TestForPreviousOutput.txt... ✓
checking TimeLimit.txt... ✓
checking Timeout_Test.txt... ✓
checking TimerIsPresent.txt... ✓
checking TimeState.txt... ✓
checking ToReactionNested.txt... ✓
checking TriggerDownstreamOnlyIfPresent2.txt... ✓
checking ActionDelay.txt... ✓
checking ActionIsPresent.txt... ✓
checking ActionWithNoReaction.txt... ✓
checking After.txt... ✓
checking AfterCycles.txt... ✓
checking AfterOverlapped.txt... ✓
checking ArrayAsParameter.txt... ✓
checking ArrayAsType.txt... ✓
checking ArrayFree.txt... ✓
checking ArrayParallel.txt... ✓
checking ArrayPrint.txt... ✓
checking ArrayScale.txt... ✓
checking CompareTags.txt... ✓
checking Composition.txt... ✓
checking CompositionAfter.txt... ✓
checking CompositionGain.txt... ✓
checking CompositionInheritance.txt... ✓
checking AsyncCallback.txt... ✓
checking AsyncCallbackNoTimer.txt... ✓
checking CountSelf.txt... ✓
checking CountTest.txt... ✓
checking DanglingOutput.txt... ✓
checking Deadline.txt... ✓
checking DeadlineHandledAbove.txt... ✓
checking DelayArray.txt... ✓
checking DelayArrayWithAfter.txt... ✓
checking DelayedAction.txt... ✓
checking DelayedReaction.txt... ✓
checking DelayInt.txt... ✓
checking DelayString.txt... ✓
checking DelayStruct.txt... ✓
checking DelayStructWithAfter.txt... ✓
checking DelayStructWithAfterOverlapped.txt... ✓
checking Determinism.txt... ✓
checking DistributedCountContainerized.txt... ✓
checking DistributedDoublePortContainerized.txt... ✓
checking DistributedMultiportContainerized.txt... ✓
checking DistributedSendClassContainerized.txt... ✓
checking DistributedStopDecentralizedContainerized.txt... ✓
checking FilesPropertyContainerized.txt... ✓
checking HelloWorldContainerized.txt... ✓
checking PingPongContainerized.txt... ✓
checking DoubleInvocation.txt... ✓
checking DoubleReaction.txt... ✓
checking BroadcastFeedback.txt... ✓
checking BroadcastFeedbackWithHierarchy.txt... ✓
checking ChainWithDelay.txt... ✓
checking CycleDetection.txt... ✓
checking DecentralizedP2PComm.txt... ✓
checking DecentralizedP2PUnbalancedTimeout.txt... ✓
checking DecentralizedP2PUnbalancedTimeoutPhysical.txt... ✓
checking DistributedBank.txt... ✓
checking DistributedBankToMultiport.txt... ✓
checking DistributedCount.txt... ✓
checking DistributedCountDecentralized.txt... ✓
checking DistributedCountDecentralizedLate.txt... ✓
checking DistributedCountDecentralizedLateDownstream.txt... ✓
checking DistributedCountDecentralizedLateHierarchy.txt... ✓
checking DistributedCountPhysical.txt... ✓
checking DistributedCountPhysicalAfterDelay.txt... ✓
checking DistributedCountPhysicalDecentralized.txt... ✓
checking DistributedDoublePort.txt... ✓
checking DistributedLoopedAction.txt... ✓
checking DistributedLoopedPhysicalAction.txt... ✓
checking DistributedLoopedPhysicalActionDecentralized.txt... ✓
checking DistributedMultiport.txt... ✓
checking DistributedMultiportToBank.txt... ✓
checking DistributedMultiportToken.txt... ✓
checking DistributedNoReact.txt... ✓
checking DistributedSendClass.txt... ✓
checking DistributedStop.txt... ✓
checking DistributedStopDecentralized.txt... ✓
checking DistributedStopZero.txt... ✓
checking DistributedStructAsType.txt... ✓
checking DistributedStructAsTypeDirect.txt... ✓
checking DistributedStructParallel.txt... ✓
checking DistributedStructPrint.txt... ✓
checking DistributedStructScale.txt... ✓
checking ClockSync.txt... ✓
checking DistributedLoopedActionDecentralized.txt... ✓
checking DistributedNetworkOrder.txt... ✓
checking LoopDistributedCentralized.txt... ✓
checking LoopDistributedCentralizedPrecedence.txt... ✓
checking LoopDistributedDecentralized.txt... ✓
checking LoopDistributedDouble.txt... ✓
checking TopLevelArtifacts.txt... ✓
checking HelloDistributed.txt... ✓
checking LoopDistributedCentralizedPrecedenceHierarchy.txt... ✓
checking ParallelDestinations.txt... ✓
checking ParallelSources.txt... ✓
checking ParallelSourcesMultiport.txt... ✓
checking PhysicalSTP.txt... ✓
checking PingPongDistributed.txt... ✓
checking StopAtShutdown.txt... ✓
checking FloatLiteral.txt... ✓
checking Gain.txt... ✓
checking GetMicroStep.txt... ✓
checking GetTime.txt... ✓
checking Hello.txt... ✓
checking HelloWorld.txt... ✓
checking Hierarchy.txt... ✓
checking Hierarchy2.txt... ✓
checking IdentifierLength.txt... ✓
checking Import.txt... ✓
checking ImportComposition.txt... ✓
checking ImportRenamed.txt... ✓
checking Count.txt... ✓
checking Imported.txt... ✓
checking ImportedAgain.txt... ✓
checking ImportedComposition.txt... ✓
checking InternalDelay.txt... ✓
checking LoopedActionSender.txt... ✓
checking Test.txt... ✓
checking TestCount.txt... ✓
checking TestCountMultiport.txt... ✓
checking ManualDelayedReaction.txt... ✓
checking Methods.txt... ✓
checking MethodsRecursive.txt... ✓
checking MethodsSameName.txt... ✓
checking Microsteps.txt... ✓
checking Minimal.txt... ✓
checking BanksCount3ModesComplex.txt... ✓
checking BanksCount3ModesSimple.txt... ✓
checking BanksModalStateReset.txt... ✓
checking ConvertCaseTest.txt... ✓
checking Count3Modes.txt... ✓
checking ModalActions.txt... ✓
checking ModalAfter.txt... ✓
checking ModalCycleBreaker.txt... ✓
checking ModalNestedReactions.txt... ✓
checking ModalStartupShutdown.txt... ✓
checking ModalStateReset.txt... ✓
checking ModalStateResetAuto.txt... ✓
checking ModalTimers.txt... ✓
checking MultipleOutputFeeder_2Connections.txt... ✓
checking MultipleOutputFeeder_ReactionConnections.txt... ✓
checking TraceTesting.txt... ✓
checking MovingAverage.txt... ✓
checking MultipleContained.txt... ✓
checking BankIndexInitializer.txt... ✓
checking BankReactionsInContainer.txt... ✓
checking BankToBank.txt... ✓
checking BankToBankMultiport.txt... ✓
checking BankToBankMultiportAfter.txt... ✓
checking BankToMultiport.txt... ✓
checking Broadcast.txt... ✓
checking BroadcastAfter.txt... ✓
checking BroadcastMultipleAfter.txt... ✓
checking MultiportFromBank.txt... ✓
checking MultiportFromBankHierarchy.txt... ✓
checking MultiportFromBankHierarchyAfter.txt... ✓
checking MultiportFromHierarchy.txt... ✓
checking MultiportFromReaction.txt... ✓
checking MultiportIn.txt... ✓
checking MultiportInParameterized.txt... ✓
checking MultiportMutableInput.txt... ✓
checking MultiportMutableInputArray.txt... ✓
checking MultiportOut.txt... ✓
checking MultiportToBank.txt... ✓
checking MultiportToBankAfter.txt... ✓
checking MultiportToBankHierarchy.txt... ✓
checking MultiportToHierarchy.txt... ✓
checking MultiportToMultiport.txt... ✓
checking MultiportToMultiport2.txt... ✓
checking MultiportToMultiport2After.txt... ✓
checking MultiportToMultiportArray.txt... ✓
checking MultiportToMultiportParameter.txt... ✓
checking MultiportToPort.txt... ✓
checking MultiportToReaction.txt... ✓
checking NestedBanks.txt... ✓
checking NestedInterleavedBanks.txt... ✓
checking PipelineAfter.txt... ✓
checking ReactionsToNested.txt... ✓
checking NativeListsAndTimes.txt... ✓
checking ParameterizedState.txt... ✓
checking PeriodicDesugared.txt... ✓
checking PingPong.txt... ✓
checking Pipeline.txt... ✓
checking Preamble.txt... ✓
checking ReadOutputOfContainedReactor.txt... ✓
checking Schedule.txt... ✓
checking ScheduleLogicalAction.txt... ✓
checking ScheduleValue.txt... ✓
checking SelfLoop.txt... ✓
checking SendingInside.txt... ✓
checking SendingInside2.txt... ✓
checking PersonProtocolBuffers.txt... ✓
checking ProtoNoPacking.txt... ✓
checking SetArray.txt... ✓
checking SimpleDeadline.txt... ✓
checking SimpleImport.txt... ✓
checking SlowingClock.txt... ✓
checking SlowingClockPhysical.txt... ✓
checking StartupOutFromInside.txt... ✓
checking Stride.txt... ✓
checking StructAsState.txt... ✓
checking StructAsType.txt... ✓
checking StructAsTypeDirect.txt... ✓
checking StructParallel.txt... ✓
checking StructPrint.txt... ✓
checking StructScale.txt... ✓
checking SubclassesAndStartup.txt... ✓
checking AfterNoTypes.txt... ✓
checking TestForPreviousOutput.txt... ✓
checking TimeLimit.txt... ✓
checking Timers.txt... ✓
checking TimeState.txt... ✓
checking TriggerDownstreamOnlyIfPresent.txt... ✓
checking TriggerDownstreamOnlyIfPresent2.txt... ✓
checking UnconnectedInput.txt... ✓
checking Wcet.txt... ✓
checking ActionDelay.txt... ✓
checking ActionImplicitDelay.txt... ✓
checking ActionIsPresent.txt... ✓
checking ActionIsPresentDouble.txt... ✓
checking ActionScheduleMicrostep.txt... ✓
checking ActionValues.txt... ✓
checking ActionValuesCleanup.txt... ✓
checking CompositionInitializationOrder.txt... ✓
checking CompositionWithPorts.txt... ✓
checking AsyncCallback.txt... ✓
checking Workers.txt... ✓
checking CtorParamDefault.txt... ✓
checking CtorParamMixed.txt... ✓
checking CtorParamSimple.txt... ✓
checking DependencyOnChildPort.txt... ✓
checking DependencyThroughChildPort.txt... ✓
checking DependencyUseAccessible.txt... ✓
checking DependencyUseNonTrigger.txt... ✓
checking DependencyUseOnLogicalAction.txt... ✓
checking FloatLiteral.txt... ✓
checking CtorParamGeneric.txt... ✓
checking CtorParamGenericInst.txt... ✓
checking GenericReactor.txt... ✓
checking Import.txt... ✓
checking ImportPreambleItem.txt... ✓
checking Imported.txt... ✓
checking ImportedAgain.txt... ✓
checking SomethingWithAPreamble.txt... ✓
checking MainReactorParam.txt... ✓
checking Minimal.txt... ✓
checking MovingAverage.txt... ✓
checking ConnectionToSelfBank.txt... ✓
checking ConnectionToSelfMultiport.txt... ✓
checking CycledLhs_SelfLoop.txt... ✓
checking CycledLhs_Single.txt... ✓
checking FullyConnected.txt... ✓
checking FullyConnectedAddressable.txt... ✓
checking MultiportFromBank.txt... ✓
checking MultiportFromHierarchy.txt... ✓
checking MultiportIn.txt... ✓
checking MultiportOut.txt... ✓
checking MultiportToBank.txt... ✓
checking MultiportToBankHierarchy.txt... ✓
checking MultiportToMultiport.txt... ✓
checking MultiportToMultiport2.txt... ✓
checking ReadOutputOfContainedBank.txt... ✓
checking WidthWithParameter.txt... ✓
checking WriteInputOfContainedBank.txt... ✓
checking NativeListsAndTimes.txt... ✓
checking PhysicalActionCanBeScheduledSynchronously.txt... ✓
checking PhysicalActionKeepaliveIsSmart.txt... ✓
checking PhysicalActionWakesSleepingScheduler.txt... ✓
checking PhysicalActionWithKeepalive.txt... ✓
checking PortConnectionInSelfInChild.txt... ✓
checking PortConnectionInSelfOutSelf.txt... ✓
checking PortConnectionOutChildOutSelf.txt... ✓
checking PortRefCleanup.txt... ✓
checking PortValueCleanup.txt... ✓
checking Preamble.txt... ✓
checking ReactionLabels.txt... ✓
checking ReservedKeywords.txt... ✓
checking SingleFileGeneration.txt... ✓
checking StateDefaultValue.txt... ✓
checking StateInitializerVisibility.txt... ✓
checking Stop.txt... ✓
checking StopAsync.txt... ✓
checking StopCleanup.txt... ✓
checking StopDuringStartup.txt... ✓
checking StopIdempotence.txt... ✓
checking StopNoEvent.txt... ✓
checking StopTimeout.txt... ✓
checking StopTimeoutExact.txt... ✓
checking StopTopology.txt... ✓
checking StructAsState.txt... ✓
checking StructAsType.txt... ✓
checking BuildProfileDefaultIsDev.txt... ✓
checking BuildProfileRelease.txt... ✓
checking CargoDependency.txt... ✓
checking CargoDependencyOnRuntime.txt... ✓
checking CliFeature.txt... ✓
checking MainParameterCanBeExpression.txt... ✓
checking ModuleDependency.txt... ✓
checking ModuleDependencyWithDirModule.txt... ✓
checking TimerDefaults.txt... ✓
checking TimerIsPresent.txt... ✓
checking TimerPeriodic.txt... ✓
checking Timers.txt... ✓
checking TimeState.txt... ✓
checking TypeVarLengthList.txt... ✓
checking ActionDelay.txt... ✓
checking ActionWithNoReaction.txt... ✓
checking After.txt... ✓
checking ArrayAsParameter.txt... ✓
checking ArrayAsType.txt... ✓
checking ArrayPrint.txt... ✓
checking ArrayScale.txt... ✓
checking Composition.txt... ✓
checking CompositionAfter.txt... ✓
checking AsyncCallback.txt... ✓
checking CountTest.txt... ✓
checking DanglingOutput.txt... ✓
checking Deadline.txt... ✓
checking DeadlineHandledAbove.txt... ✓
checking DelayedAction.txt... ✓
checking DelayedReaction.txt... ✓
checking DelayInt.txt... ✓
checking Determinism.txt... ✓
checking DistributedCountContainerized.txt... ✓
checking HelloWorldContainerized.txt... ✓
checking DoubleInvocation.txt... ✓
checking DoubleReaction.txt... ✗
1) all
0 passing (2s)
1 failing
1) test syntax highlighting
all:
AssertionError: expected '<span class="source-lf comment-line-double-dash-lflang">// Test that two simultaneous inputs that trigger a reaction trigger it only</span>\n<span class="source-lf comment-line-double-dash-lflang">// once. Correct output for this 2, 4, 6, 8, etc.</span>\n<span class="source-lf meta-targetspec-lflang keyword-control-lflang">target</span><span class="source-lf meta-targetspec-lflang"> </span><span class="source-lf meta-targetspec-lflang constant-language-lflang">TypeScript</span><span class="source-lf meta-targetspec-lflang"> {</span>\n<span class="source-lf meta-targetspec-lflang"> </span><span class="source-lf meta-targetspec-lflang variable-parameter-lflang">timeout</span><span class="source-lf meta-targetspec-lflang">: </span><span class="source-lf meta-targetspec-lflang constant-numeric-int-lflang">10</span><span class="source-lf meta-targetspec-lflang"> </span><span class="source-lf meta-targetspec-lflang constant-numeric-lflang">sec</span><span class="source-lf meta-targetspec-lflang">,</span>\n<span class="source-lf meta-targetspec-lflang"> </span><span class="source-lf meta-targetspec-lflang variable-parameter-lflang">fast</span><span class="source-lf meta-targetspec-lflang">: </span><span class="source-lf meta-targetspec-lflang constant-language-lflang">true</span>\n<span class="source-lf meta-targetspec-lflang">}</span>\n<span class="source-lf"></span>\n<span class="source-lf storage-modifier-lflang">reactor</span><span class="source-lf"> </span><span class="source-lf entity-name-type-lflang">Clock</span><span class="source-lf">(offset: </span><span class="source-lf storage-type-lflang">time</span><span class="source-lf">(</span><span class="source-lf constant-numeric-int-lflang">0</span><span class="source-lf">), period: </span><span class="source-lf storage-type-lflang">time</span><span class="source-lf">(</span><span class="source-lf constant-numeric-int-lflang">1</span><span class="source-lf"> </span><span class="source-lf constant-numeric-lflang">sec</span><span class="source-lf">)) {</span>\n<span class="source-lf"> </span><span class="source-lf storage-modifier-lflang">output</span><span class="source-lf"> y: </span><span class="source-lf storage-type-lflang">number</span>\n<span class="source-lf"> </span><span class="source-lf storage-modifier-lflang">timer</span><span class="source-lf"> t(offset, period)</span>\n<span class="source-lf"> </span><span class="source-lf storage-modifier-lflang">state</span><span class="source-lf"> count: </span><span class="source-lf storage-type-lflang">number</span><span class="source-lf">(</span><span class="source-lf constant-numeric-int-lflang">0</span><span class="source-lf">)</span>\n<span class="source-lf"></span>\n<span class="source-lf"> </span><span class="source-lf keyword-control-lflang">reaction</span><span class="source-lf">(t) </span><span class="source-lf keyword-operator-lflang">-></span><span class="source-lf"> y {</span><span class="source-lf keyword-operator-lflang">=</span>\n<span class="source-lf"> count</span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf">;</span>\n<span class="source-lf"> y </span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> count;</span>\n<span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf">}</span>\n<span class="source-lf">}</span>\n<span class="source-lf"></span>\n<span class="source-lf storage-modifier-lflang">reactor</span><span class="source-lf"> </span><span class="source-lf entity-name-type-lflang">Destination</span><span class="source-lf"> {</span>\n<span class="source-lf"> </span><span class="source-lf storage-modifier-lflang">input</span><span class="source-lf"> x: </span><span class="source-lf storage-type-lflang">number</span>\n<span class="source-lf"> </span><span class="source-lf storage-modifier-lflang">input</span><span class="source-lf"> w: </span><span class="source-lf storage-type-lflang">number</span>\n<span class="source-lf"> </span><span class="source-lf storage-modifier-lflang">state</span><span class="source-lf"> s: </span><span class="source-lf storage-type-lflang">number</span><span class="source-lf">(</span><span class="source-lf constant-numeric-int-lflang">2</span><span class="source-lf">)</span>\n<span class="source-lf"></span>\n<span class="source-lf"> </span><span class="source-lf keyword-control-lflang">reaction</span><span class="source-lf">(x, w) {</span><span class="source-lf keyword-operator-lflang">=</span>\n<span class="source-lf"> let sum </span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> </span><span class="source-lf constant-numeric-int-lflang">0</span><span class="source-lf">;</span>\n<span class="source-lf"> if (x) {</span>\n<span class="source-lf"> sum </span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> x;</span>\n<span class="source-lf"> }</span>\n<span class="source-lf"> if (w) {</span>\n<span class="source-lf"> sum </span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> w;</span>\n<span class="source-lf"> }</span>\n<span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">console</span><span class="source-lf keyword-operator-lflang">.</span><span class="source-lf variable-other-lflang">log</span><span class="source-lf">(</span><span class="source-lf string-quoted-double-lflang">"</span><span class="source-lf string-quoted-double-lflang">Sum of inputs is: </span><span class="source-lf string-quoted-double-lflang">"</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf"> sum);</span>\n<span class="source-lf"> if (sum !</span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> s) {</span>\n<span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">util</span><span class="source-lf keyword-operator-lflang">.</span><span class="source-lf variable-other-lflang">requestErrorStop</span><span class="source-lf">(</span><span class="source-lf string-quoted-double-lflang">"</span><span class="source-lf string-quoted-double-lflang">FAILURE: Expected sum to be </span><span class="source-lf string-quoted-double-lflang">"</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf"> s </span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf"> </span><span class="source-lf string-quoted-double-lflang">"</span><span class="source-lf string-quoted-double-lflang">, but it was </span><span class="source-lf string-quoted-double-lflang">"</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf"> sum)</span>\n<span class="source-lf"> }</span>\n<span class="source-lf"> s </span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> </span><span class="source-lf constant-numeric-int-lflang">2</span><span class="source-lf">;</span>\n<span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf">}</span>\n<span class="source-lf">}</span>\n<span class="source-lf"></span>\n<span class="source-lf storage-modifier-lflang">main</span><span class="source-lf"> </span><span class="source-lf storage-modifier-lflang">reactor</span><span class="source-lf"> </span><span class="source-lf entity-name-type-lflang">DoubleReaction</span><span class="source-lf"> {</span>\n<span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">c1</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> </span><span class="source-lf keyword-operator-new-lflang">new</span><span class="source-lf"> </span><span class="source-lf entity-name-type-lflang">Clock</span><span class="source-lf">()</span>\n<span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">c2</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> </span><span class="source-lf keyword-operator-new-lflang">new</span><span class="source-lf"> </span><span class="source-lf entity-name-type-lflang">Clock</span><span class="source-lf">()</span>\n<span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">d</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> </span><span class="source-lf keyword-operator-new-lflang">new</span><span class="source-lf"> </span><span class="source-lf entity-name-type-lflang">Destination</span><span class="source-lf">()</span>\n<span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">c1</span><span class="source-lf keyword-operator-lflang">.</span><span class="source-lf variable-other-lflang">y</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">-></span><span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">d</span><span class="source-lf keyword-operator-lflang">.</span><span class="source-lf variable-other-lflang">x</span>\n<span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">c2</span><span class="source-lf keyword-operator-lflang">.</span><span class="source-lf variable-other-lflang">y</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">-></span><span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">d</span><span class="source-lf keyword-operator-lflang">.</span><span class="source-lf variable-other-lflang">w</span>\n<span class="source-lf">}</span>\n<span class="source-lf"></span>\n' to deeply equal '<span class="source-lf comment-line-double-dash-lflang">// Test that two simultaneous inputs that trigger a reaction trigger it only</span>\n<span class="source-lf comment-line-double-dash-lflang">// once. Correct output for this 2, 4, 6, 8, etc.</span>\n<span class="source-lf meta-targetspec-lflang">target</span><span class="source-lf meta-targetspec-lflang"> </span><span class="source-lf meta-targetspec-lflang constant-language-lflang">TypeScript</span><span class="source-lf meta-targetspec-lflang"> {</span>\n<span class="source-lf meta-targetspec-lflang"> </span><span class="source-lf meta-targetspec-lflang variable-parameter-lflang">timeout</span><span class="source-lf meta-targetspec-lflang">: </span><span class="source-lf meta-targetspec-lflang constant-numeric-int-lflang">10</span><span class="source-lf meta-targetspec-lflang"> </span><span class="source-lf meta-targetspec-lflang constant-numeric-lflang">sec</span><span class="source-lf meta-targetspec-lflang">,</span>\n<span class="source-lf meta-targetspec-lflang"> </span><span class="source-lf meta-targetspec-lflang variable-parameter-lflang">fast</span><span class="source-lf meta-targetspec-lflang">: </span><span class="source-lf meta-targetspec-lflang constant-language-lflang">true</span>\n<span class="source-lf meta-targetspec-lflang">}</span>\n<span class="source-lf"></span>\n<span class="source-lf storage-modifier-lflang">reactor</span><span class="source-lf"> </span><span class="source-lf entity-name-type-lflang">Clock</span><span class="source-lf">(offset: </span><span class="source-lf storage-type-lflang">time</span><span class="source-lf">(</span><span class="source-lf constant-numeric-int-lflang">0</span><span class="source-lf">), period: </span><span class="source-lf storage-type-lflang">time</span><span class="source-lf">(</span><span class="source-lf constant-numeric-int-lflang">1</span><span class="source-lf"> </span><span class="source-lf constant-numeric-lflang">sec</span><span class="source-lf">)) {</span>\n<span class="source-lf"> </span><span class="source-lf storage-modifier-lflang">output</span><span class="source-lf"> y: </span><span class="source-lf storage-type-lflang">number</span>\n<span class="source-lf"> </span><span class="source-lf storage-modifier-lflang">timer</span><span class="source-lf"> t(offset, period)</span>\n<span class="source-lf"> </span><span class="source-lf storage-modifier-lflang">state</span><span class="source-lf"> count: </span><span class="source-lf storage-type-lflang">number</span><span class="source-lf">(</span><span class="source-lf constant-numeric-int-lflang">0</span><span class="source-lf">)</span>\n<span class="source-lf"></span>\n<span class="source-lf"> </span><span class="source-lf keyword-control-lflang">reaction</span><span class="source-lf">(t) </span><span class="source-lf keyword-operator-lflang">-></span><span class="source-lf"> y {</span><span class="source-lf keyword-operator-lflang">=</span>\n<span class="source-lf"> count</span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf">;</span>\n<span class="source-lf"> y </span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> count;</span>\n<span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf">}</span>\n<span class="source-lf">}</span>\n<span class="source-lf"></span>\n<span class="source-lf storage-modifier-lflang">reactor</span><span class="source-lf"> </span><span class="source-lf entity-name-type-lflang">Destination</span><span class="source-lf"> {</span>\n<span class="source-lf"> </span><span class="source-lf storage-modifier-lflang">input</span><span class="source-lf"> x: </span><span class="source-lf storage-type-lflang">number</span>\n<span class="source-lf"> </span><span class="source-lf storage-modifier-lflang">input</span><span class="source-lf"> w: </span><span class="source-lf storage-type-lflang">number</span>\n<span class="source-lf"> </span><span class="source-lf storage-modifier-lflang">state</span><span class="source-lf"> s: </span><span class="source-lf storage-type-lflang">number</span><span class="source-lf">(</span><span class="source-lf constant-numeric-int-lflang">2</span><span class="source-lf">)</span>\n<span class="source-lf"></span>\n<span class="source-lf"> </span><span class="source-lf keyword-control-lflang">reaction</span><span class="source-lf">(x, w) {</span><span class="source-lf keyword-operator-lflang">=</span>\n<span class="source-lf"> let sum </span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> </span><span class="source-lf constant-numeric-int-lflang">0</span><span class="source-lf">;</span>\n<span class="source-lf"> if (x) {</span>\n<span class="source-lf"> sum </span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> x;</span>\n<span class="source-lf"> }</span>\n<span class="source-lf"> if (w) {</span>\n<span class="source-lf"> sum </span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> w;</span>\n<span class="source-lf"> }</span>\n<span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">console</span><span class="source-lf keyword-operator-lflang">.</span><span class="source-lf variable-other-lflang">log</span><span class="source-lf">(</span><span class="source-lf string-quoted-double-lflang">"</span><span class="source-lf string-quoted-double-lflang">Sum of inputs is: </span><span class="source-lf string-quoted-double-lflang">"</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf"> sum);</span>\n<span class="source-lf"> if (sum !</span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> s) {</span>\n<span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">util</span><span class="source-lf keyword-operator-lflang">.</span><span class="source-lf variable-other-lflang">requestErrorStop</span><span class="source-lf">(</span><span class="source-lf string-quoted-double-lflang">"</span><span class="source-lf string-quoted-double-lflang">FAILURE: Expected sum to be </span><span class="source-lf string-quoted-double-lflang">"</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf"> s </span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf"> </span><span class="source-lf string-quoted-double-lflang">"</span><span class="source-lf string-quoted-double-lflang">, but it was </span><span class="source-lf string-quoted-double-lflang">"</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf"> sum)</span>\n<span class="source-lf"> }</span>\n<span class="source-lf"> s </span><span class="source-lf keyword-operator-lflang">+</span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> </span><span class="source-lf constant-numeric-int-lflang">2</span><span class="source-lf">;</span>\n<span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf">}</span>\n<span class="source-lf">}</span>\n<span class="source-lf"></span>\n<span class="source-lf storage-modifier-lflang">main</span><span class="source-lf"> </span><span class="source-lf storage-modifier-lflang">reactor</span><span class="source-lf"> </span><span class="source-lf entity-name-type-lflang">DoubleReaction</span><span class="source-lf"> {</span>\n<span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">c1</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> </span><span class="source-lf keyword-operator-new-lflang">new</span><span class="source-lf"> </span><span class="source-lf entity-name-type-lflang">Clock</span><span class="source-lf">()</span>\n<span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">c2</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> </span><span class="source-lf keyword-operator-new-lflang">new</span><span class="source-lf"> </span><span class="source-lf entity-name-type-lflang">Clock</span><span class="source-lf">()</span>\n<span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">d</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">=</span><span class="source-lf"> </span><span class="source-lf keyword-operator-new-lflang">new</span><span class="source-lf"> </span><span class="source-lf entity-name-type-lflang">Destination</span><span class="source-lf">()</span>\n<span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">c1</span><span class="source-lf keyword-operator-lflang">.</span><span class="source-lf variable-other-lflang">y</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">-></span><span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">d</span><span class="source-lf keyword-operator-lflang">.</span><span class="source-lf variable-other-lflang">x</span>\n<span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">c2</span><span class="source-lf keyword-operator-lflang">.</span><span class="source-lf variable-other-lflang">y</span><span class="source-lf"> </span><span class="source-lf keyword-operator-lflang">-></span><span class="source-lf"> </span><span class="source-lf variable-other-constant-reactorinstance-lflang">d</span><span class="source-lf keyword-operator-lflang">.</span><span class="source-lf variable-other-lflang">w</span>\n<span class="source-lf">}</span>\n<span class="source-lf"></span>\n'
+ expected - actual
<span class="source-lf comment-line-double-dash-lflang">// Test that two simultaneous inputs that trigger a reaction trigger it only</span>
<span class="source-lf comment-line-double-dash-lflang">// once. Correct output for this 2, 4, 6, 8, etc.</span>
-<span class="source-lf meta-targetspec-lflang keyword-control-lflang">target</span><span class="source-lf meta-targetspec-lflang"> </span><span class="source-lf meta-targetspec-lflang constant-language-lflang">TypeScript</span><span class="source-lf meta-targetspec-lflang"> {</span>
+<span class="source-lf meta-targetspec-lflang">target</span><span class="source-lf meta-targetspec-lflang"> </span><span class="source-lf meta-targetspec-lflang constant-language-lflang">TypeScript</span><span class="source-lf meta-targetspec-lflang"> {</span>
<span class="source-lf meta-targetspec-lflang"> </span><span class="source-lf meta-targetspec-lflang variable-parameter-lflang">timeout</span><span class="source-lf meta-targetspec-lflang">: </span><span class="source-lf meta-targetspec-lflang constant-numeric-int-lflang">10</span><span class="source-lf meta-targetspec-lflang"> </span><span class="source-lf meta-targetspec-lflang constant-numeric-lflang">sec</span><span class="source-lf meta-targetspec-lflang">,</span>
<span class="source-lf meta-targetspec-lflang"> </span><span class="source-lf meta-targetspec-lflang variable-parameter-lflang">fast</span><span class="source-lf meta-targetspec-lflang">: </span><span class="source-lf meta-targetspec-lflang constant-language-lflang">true</span>
<span class="source-lf meta-targetspec-lflang">}</span>
<span class="source-lf"></span>
at Context.<anonymous> (out/test/test/check_highlighting.test.js:100:68)
My concern is that it's not easy to see what's wrong about the HTML code, even though it might be obvious to see when rendered. Why not render it as a webpage?
My concern is that it's not easy to see what's wrong about the HTML code, even though it might be obvious to see when rendered. Why not render it as a webpage?
OK, I will take it as an action item to try something like this.
My concern is that it's not easy to see what's wrong about the HTML code, even though it might be obvious to see when rendered. Why not render it as a webpage?
OK, I will take it as an action item to try something like this.
On second thought, can we please not do this? At some point we will end up writing a web app just to be able to run our tests, and our tests themselves will need tests... The HTML is the most explicit and unambiguous representation of the syntax annotations that is possible. If it is too hard to read, then you can always just rebuild the VS Code extension and view the file. Viewing files using the VS Code extension is a very efficient way to see the effects of the highlighting, and it lets you visually inspect many files quickly without having to learn to use another testing tool.
It sounds like you may have checked out a different
lingua-franca
submodule from the one that is tracked in this branch. If you executegit submodule update --init
, and rerun the test, does it pass?
yes, this was it, thanks! tests look good now.
Implements the behavior that I discussed today with @lhstrh and @jesslin02.
I am pleased to find that this test terminates in roughly 2 seconds on my laptop, regardless of whether it is creating new known-good results or comparing against them, even though it is running on all 908 of our
lingua-franca
tests. If only all of our project's integration tests could terminate in 2 seconds :sweat_smile:This duplicates code which can be found in
website-lingua-franca
. I opted not to create a submodule. The purpose of this code is different from the purpose of the code inwebsite-lingua-franca
, and it is OK for code with a different purpose to evolve independently. Besides -- it is only a 50ish-line snippet that is copied and pasted.I am concerned that HTML is too verbose and hard to read.
For now, I propose to stick with the HTML annotations. If their verbosity is a serious problem for us in practice, then we can revisit them.