1
0

Makefile.toml 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. [config]
  2. default_to_workspace = false
  3. min_version = "0.32.4"
  4. [env]
  5. CARGO_MAKE_CLIPPY_ARGS = "-- --deny=warnings"
  6. CARGO_MAKE_EXTEND_WORKSPACE_MAKEFILE = true
  7. [config.modify_core_tasks]
  8. namespace = "core"
  9. private = true
  10. [tasks.tests-setup]
  11. private = true
  12. script = [
  13. """
  14. test_flags = array --headless --firefox
  15. dioxus_test_features = set wasm_test
  16. dioxus_test_flags = array_join ${test_flags} " "
  17. echo "running tests with flags: ${dioxus_test_flags} and features: ${dioxus_test_features}"
  18. set_env DIOXUS_TEST_FLAGS ${dioxus_test_flags}
  19. set_env DIOXUS_TEST_FEATURES ${dioxus_test_features}
  20. """,
  21. ]
  22. script_runner = "@duckscript"
  23. [tasks.tests]
  24. category = "Testing"
  25. dependencies = ["tests-setup"]
  26. description = "Run all tests"
  27. env = {CARGO_MAKE_WORKSPACE_SKIP_MEMBERS = ["**/examples/*"]}
  28. run_task = {name = ["test-flow", "test-with-browser"], fork = true}
  29. [tasks.build]
  30. command = "cargo"
  31. args = ["build"]
  32. [tasks.test-flow]
  33. dependencies = ["test"]
  34. private = true
  35. [tasks.test]
  36. dependencies = ["build"]
  37. command = "cargo"
  38. args = ["test", "--lib", "--bins", "--tests", "--examples", "--workspace", "--exclude", "dioxus-router"]
  39. private = true
  40. [tasks.test-with-browser]
  41. env = { CARGO_MAKE_WORKSPACE_INCLUDE_MEMBERS = ["**/packages/router"] }
  42. private = true
  43. workspace = true