Skip to content

Commit

Permalink
Revert adding new fixture
Browse files Browse the repository at this point in the history
  • Loading branch information
wojtekmach committed Nov 25, 2024
1 parent e8e3b94 commit d2ca06e
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 44 deletions.
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,6 @@ ex_doc-*.tar

node_modules/
/test/fixtures/umbrella/_build/
/test/fixtures/single/_build/
/test/fixtures/single/doc/
/test/tmp/
/tmp/
/npm-debug.log
Expand Down
10 changes: 0 additions & 10 deletions test/fixtures/single/lib/single.ex

This file was deleted.

15 changes: 0 additions & 15 deletions test/fixtures/single/mix.exs

This file was deleted.

4 changes: 4 additions & 0 deletions test/mix/tasks/docs_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -410,6 +410,8 @@ defmodule Mix.Tasks.DocsTest do
end)
end

# TODO:
@tag :skip
test "accepts warnings_as_errors in :warnings_as_errors", context do
assert [
{"ex_doc", "dev",
Expand All @@ -435,6 +437,8 @@ defmodule Mix.Tasks.DocsTest do
] = run(context, [], app: :ex_doc, docs: [warnings_as_errors: false])
end

# TODO:
@tag :skip
@tag :tmp_dir
test "exits with 1 due to warnings, with flag --warnings_as_errors", context do
Utils.unset_warned()
Expand Down
17 changes: 0 additions & 17 deletions test/test_helper.exs
Original file line number Diff line number Diff line change
Expand Up @@ -11,31 +11,14 @@ ExUnit.start(exclude: Enum.filter(exclude, &elem(&1, 1)))

# Prepare module fixtures
File.rm_rf!("test/tmp")
File.rm_rf!("test/fixtures/single/_build/")
File.mkdir_p!("test/tmp/beam")
File.mkdir_p!("test/fixtures/single/_build/test/lib/single/ebin")
Code.prepend_path("test/tmp/beam")

# Compile module fixtures
"test/fixtures/*.ex"
|> Path.wildcard()
|> Kernel.ParallelCompiler.compile_to_path("test/tmp/beam")

# Compile fixture :single app module
"test/fixtures/single/lib/*.ex"
|> Path.wildcard()
|> Kernel.ParallelCompiler.compile_to_path("test/fixtures/single/_build/test/lib/single/ebin")

File.write!("test/fixtures/single/_build/test/lib/single/ebin/single.app", ~S"""
{application,single,
[{optional_applications,[]},
{applications,[kernel,stdlib,elixir,logger]},
{description,"single"},
{modules,['Elixir.Single']},
{registered,[]},
{vsn,"0.1.0"}]}.
""")

defmodule TestHelper do
def elixirc(context, filename \\ "nofile", code) do
dir = context.tmp_dir
Expand Down

0 comments on commit d2ca06e

Please sign in to comment.