We usually try to keep the core language as simple as possible. However Elixir provides all the extensibility that allows you to implement something like this yourself, for example by defining your own test macros. We usually advise to start with a library and see how it goes, and I think that would be a great idea here as well!
On Mon, 18 Mar 2019 at 19:08, <[email protected]> wrote: > describe "my test case" do > test_cases_for ["should do something with users", "should do > something else with users"], do: > [ > %{username: "Foobar1", likes_to: ["play soccer"]}, > %{username: "Foobar2", likes_to: ["play basketball", "go on a > trip"]}, > %{username: "Foobar3", likes_to: []}, > ] > > #Loops into test_cases > test "should do something with users", cases: %{username: username, > likes_to: likes_to} do > #Do something with those params > end > > > test "should do something else with users", cases: %{username: username, > likes_to: likes_to} do > #Do something with those params > end > end > > I think it would be cool if ExUnit had something like this, isn`t it? > > -- > You received this message because you are subscribed to the Google Groups > "elixir-lang-core" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/elixir-lang-core/36931be4-2d15-435b-8d64-f9829f6a0dac%40googlegroups.com > <https://groups.google.com/d/msgid/elixir-lang-core/36931be4-2d15-435b-8d64-f9829f6a0dac%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- Andrea Leopardi [email protected] -- You received this message because you are subscribed to the Google Groups "elixir-lang-core" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/elixir-lang-core/CAM9Rf%2BKFyMxs_YOrzSf%3Df_X6btpiLOxgvoKv4SziTNBuJa2s8Q%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
