From 37c67892de91eeb32f4b735ed149eb306fcbdbd9 Mon Sep 17 00:00:00 2001 From: Joshua Grosso Date: Fri, 17 May 2024 15:32:05 -0700 Subject: [PATCH] Work towards making the tests valid standalone files (see #80) --- .../Haskell/errors/Sourcemap1.axel_golden | 2 +- .../Haskell/errors/Sourcemap1.error_golden | 14 ++++++---- .../errors/ThroughQuasiquote.axel_golden | 2 +- .../errors/ThroughQuasiquote.error_golden | 28 ++++++++----------- 4 files changed, 22 insertions(+), 24 deletions(-) diff --git a/test/Axel/Test/Haskell/errors/Sourcemap1.axel_golden b/test/Axel/Test/Haskell/errors/Sourcemap1.axel_golden index b9cb4a9..c14b225 100644 --- a/test/Axel/Test/Haskell/errors/Sourcemap1.axel_golden +++ b/test/Axel/Test/Haskell/errors/Sourcemap1.axel_golden @@ -1,5 +1,5 @@ (module Sourcemap1) -(=macro test [] undefinedFunction) +(=macro test [] unit) (test) diff --git a/test/Axel/Test/Haskell/errors/Sourcemap1.error_golden b/test/Axel/Test/Haskell/errors/Sourcemap1.error_golden index 5ec8144..3031165 100644 --- a/test/Axel/Test/Haskell/errors/Sourcemap1.error_golden +++ b/test/Axel/Test/Haskell/errors/Sourcemap1.error_golden @@ -2,12 +2,14 @@ While compiling 'Sourcemap1': While expanding (test): -[47 of 48] Compiling AutogeneratedAxelMacroDefinitionAndEnvironment8691214048254095332 ( axelTemp/8691214048254095332/AutogeneratedAxelMacroDefinitionAndEnvironment8691214048254095332.hs, interpreted ) - Variable not in scope: - undefinedFunction - :: AxelRuntime_GHCPrelude.IO - [AxelRuntime_AST.Expression AxelRuntime_Sourcemap.SourceMetadata] -The above message is in terms of the generated Haskell, at axelTemp/8691214048254095332/AutogeneratedAxelMacroDefinitionAndEnvironment8691214048254095332.hs:9:47. +[40 of 48] Compiling AutogeneratedAxelMacroDefinitionAndEnvironment3271698982841329388 ( axelTemp/3271698982841329388/AutogeneratedAxelMacroDefinitionAndEnvironment3271698982841329388.hs, interpreted ) + • Couldn't match expected type ‘AxelRuntime_GHCPrelude.IO + [AxelRuntime_AST.Expression AxelRuntime_Sourcemap.SourceMetadata]’ + with actual type ‘()’ + • In the expression: () + In an equation for ‘test_AXEL_AUTOGENERATED_MACRO_DEFINITION’: + test_AXEL_AUTOGENERATED_MACRO_DEFINITION [] = () +The above message is in terms of the generated Haskell, at axelTemp/3271698982841329388/AutogeneratedAxelMacroDefinitionAndEnvironment3271698982841329388.hs:9:47. Try checking at Sourcemap1:3:17. If the Axel code at that position doesn't seem related, something may have gone wrong during a macro expansion. Failed, 46 modules loaded. \ No newline at end of file diff --git a/test/Axel/Test/Haskell/errors/ThroughQuasiquote.axel_golden b/test/Axel/Test/Haskell/errors/ThroughQuasiquote.axel_golden index c0a53d1..7963dbc 100644 --- a/test/Axel/Test/Haskell/errors/ThroughQuasiquote.axel_golden +++ b/test/Axel/Test/Haskell/errors/ThroughQuasiquote.axel_golden @@ -4,6 +4,6 @@ (=macro test ([x]) (pure [`(~x arg1 arg2)])) -(=macro test2 [] (test undefinedFunction)) +(=macro test2 [] (test +)) (test2) \ No newline at end of file diff --git a/test/Axel/Test/Haskell/errors/ThroughQuasiquote.error_golden b/test/Axel/Test/Haskell/errors/ThroughQuasiquote.error_golden index ac786ca..b3fa6a1 100644 --- a/test/Axel/Test/Haskell/errors/ThroughQuasiquote.error_golden +++ b/test/Axel/Test/Haskell/errors/ThroughQuasiquote.error_golden @@ -2,24 +2,20 @@ While compiling 'ThroughQuasiquote': While expanding (test2): -[49 of 50] Compiling AutogeneratedAxelMacroDefinitionAndEnvironment2198386876840781157 ( axelTemp/2198386876840781157/AutogeneratedAxelMacroDefinitionAndEnvironment2198386876840781157.hs, interpreted ) +[42 of 50] Compiling AutogeneratedAxelMacroDefinitionAndEnvironment4444071668684652943 ( axelTemp/4444071668684652943/AutogeneratedAxelMacroDefinitionAndEnvironment4444071668684652943.hs, interpreted ) Variable not in scope: - undefinedFunction - :: t0 - -> t1 - -> IO - [AxelRuntime_AST.Expression AxelRuntime_Sourcemap.SourceMetadata] -The above message is in terms of the generated Haskell, at axelTemp/2198386876840781157/AutogeneratedAxelMacroDefinitionAndEnvironment2198386876840781157.hs:11:49. -Try checking at axelTemp/6713099704434341978/result.axel:1:2. + arg1 + :: IO + [AxelRuntime_AST.Expression AxelRuntime_Sourcemap.SourceMetadata] +The above message is in terms of the generated Haskell, at axelTemp/4444071668684652943/AutogeneratedAxelMacroDefinitionAndEnvironment4444071668684652943.hs:11:53. +Try checking at axelTemp/7079426989737659938/result.axel:1:4. If the Axel code at that position doesn't seem related, something may have gone wrong during a macro expansion. - Variable not in scope: arg1 -The above message is in terms of the generated Haskell, at axelTemp/2198386876840781157/AutogeneratedAxelMacroDefinitionAndEnvironment2198386876840781157.hs:11:67. -Try checking at axelTemp/6713099704434341978/result.axel:1:20. -If the Axel code at that position doesn't seem related, something may have gone wrong during a macro expansion. - - Variable not in scope: arg2 -The above message is in terms of the generated Haskell, at axelTemp/2198386876840781157/AutogeneratedAxelMacroDefinitionAndEnvironment2198386876840781157.hs:11:72. -Try checking at axelTemp/6713099704434341978/result.axel:1:25. + Variable not in scope: + arg2 + :: IO + [AxelRuntime_AST.Expression AxelRuntime_Sourcemap.SourceMetadata] +The above message is in terms of the generated Haskell, at axelTemp/4444071668684652943/AutogeneratedAxelMacroDefinitionAndEnvironment4444071668684652943.hs:11:58. +Try checking at axelTemp/7079426989737659938/result.axel:1:9. If the Axel code at that position doesn't seem related, something may have gone wrong during a macro expansion. Failed, 48 modules loaded. \ No newline at end of file