cleanup
This commit is contained in:
parent
6c243439a9
commit
07d92aed97
@ -220,8 +220,8 @@ defmodule Tdd.Debug do
|
||||
end
|
||||
trace_data = get_and_clear_trace_data()
|
||||
disable_tracing()
|
||||
trace_data
|
||||
|> IO.inspect()
|
||||
# trace_data
|
||||
# |> IO.inspect()
|
||||
binary = JSON.encode!(trace_data)
|
||||
File.write("trace.json", binary)
|
||||
{outcome, trace_data}
|
||||
|
||||
12
new.exs
12
new.exs
@ -2749,9 +2749,7 @@ defmodule CompilerAlgoTests do
|
||||
|
||||
# --- Section: Basic Subtyping ---
|
||||
IO.puts("\n--- Section: Basic Subtyping ---")
|
||||
Tdd.Debug.enable_tracing()
|
||||
test_subtype(":foo <: atom", true, {:literal, :foo}, :atom)
|
||||
Tdd.Debug.disable_tracing()
|
||||
test_subtype("atom <: :foo", false, :atom, {:literal, :foo})
|
||||
test_subtype(":foo <: integer", false, {:literal, :foo}, :integer)
|
||||
test_subtype("int==5 <: integer", true, {:literal, 5}, :integer)
|
||||
@ -2988,12 +2986,14 @@ defmodule TddCompilerRecursiveTests do
|
||||
{:list_of, :integer}
|
||||
)
|
||||
|
||||
# Tdd.Debug.run(fn ->
|
||||
test_subtype(
|
||||
"list_of(supertype) is not a subtype of list_of(subtype)",
|
||||
false,
|
||||
{:list_of, :integer},
|
||||
{:list_of, {:literal, 1}}
|
||||
)
|
||||
# end)
|
||||
|
||||
list_with_int = {:cons, :integer, {:literal, []}}
|
||||
list_of_atoms = {:list_of, :atom}
|
||||
@ -3006,7 +3006,7 @@ defmodule TddCompilerRecursiveTests do
|
||||
)
|
||||
|
||||
list_with_atom = {:cons, :atom, {:literal, []}}
|
||||
Tdd.Debug.run(fn ->
|
||||
# Tdd.Debug.run(fn ->
|
||||
|
||||
test_subtype(
|
||||
"a list with a correct element type is a subtype of list_of(E)",
|
||||
@ -3014,7 +3014,7 @@ Tdd.Debug.run(fn ->
|
||||
list_with_atom,
|
||||
list_of_atoms
|
||||
)
|
||||
end)
|
||||
# end)
|
||||
|
||||
# --- Equivalence tests ---
|
||||
IO.puts("\n--- Section: Equivalence ---")
|
||||
@ -3096,11 +3096,7 @@ Tdd.Debug.run(fn ->
|
||||
end
|
||||
end
|
||||
|
||||
# Ensure the tracing state manager is started
|
||||
# Tdd.Debug.init()
|
||||
Process.sleep(100)
|
||||
# To run this new test, add the following to your main test runner script:
|
||||
# TddCompilerRecursiveTests.run()
|
||||
TypeSpecTests.run()
|
||||
TddStoreTests.run()
|
||||
TddVariableTests.run()
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user