Yes, even another library. You can run it in test while you are in test.

And the error message says it must be a relative path pointing inside the
current directory, IIRC.

On Fri, Mar 17, 2023 at 20:26 Brandon Gillespie <bran...@cold.org> wrote:

> On 3/16/23 5:00 PM, José Valim wrote:
>
> > You shouldn't need to bundle test code into your production code.
> >
> > 1. Deps are compiled in prod but in_umbrella deps are compiled in the
> > same environment as the current project. You can achieve this by
> > specifying the env option to the dependency, such as "env: Mix.env()",
> > and it works for any dependency
>
>
> Even when this is a library? So "your production code" becomes muddied.
> I create a library, I post it to hex.pm, then another app uses this
> library—how can it use the library's ex_machina test factories?
>
>
> > > So I'm not sure why it effectively said "this thing I'm holding
> > doesn't exist."
> >
> > That's now what it says. It says that it must be either relative from
> > the current dir or absolute to anywhere. :)
>
>
> But it is relative and that's my confusion :)
>
> I gave it the path "../../deps/rivet_ident/test/lib" and it found the
> actual factory, it then gave the absolute path to that factory as part
> of the error, and the absolute path was correct, yet it said it couldn't
> use it. This is what confused me.
>
>
> -Brandon
>
> --
> 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 elixir-lang-core+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/elixir-lang-core/0e3006c8-aa9e-c360-ad37-16374554ab7a%40cold.org
> .
>

-- 
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 elixir-lang-core+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elixir-lang-core/CAGnRm4%2B%2BYiTSNiaytuBkJNyiFnfo%2BPiVs5-BRkPaj0Cx6DvKpg%40mail.gmail.com.

Reply via email to