# What's the official way to keep track of package test dependencies that are not needed by a Package?

**URL:** https://discourse.julialang.org/t/whats-the-official-way-to-keep-track-of-package-test-dependencies-that-are-not-needed-by-a-package/28202
**Category:** New to Julia
**Created:** [August 30, 2019, 10:30am UTC](https://discourse.julialang.org/t/whats-the-official-way-to-keep-track-of-package-test-dependencies-that-are-not-needed-by-a-package/28202 "2019-08-30T10:30:26Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![xiaodai](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/xiaodai/32/15937_2.png) [@xiaodai](https://discourse.julialang.org/u/xiaodai)
#### Post date: [August 30, 2019, 10:30am UTC](https://discourse.julialang.org/t/whats-the-official-way-to-keep-track-of-package-test-dependencies-that-are-not-needed-by-a-package/28202/1 "2019-08-30T10:30:26Z")

</div>

Say I have am developing PkgA and I needed PkgB and PkgC for PkgA to work. I know can just `]add` these. What about PkgD and PkgE that I only need in testing my PkgA? What’s the official and recommended way to keep track on them? Should they be added to Project.toml somehow?

---

<div class="post-metadata">

### Author: ![kevbonham](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kevbonham/32/216165_2.png) [@kevbonham](https://discourse.julialang.org/u/kevbonham)
#### Post date: [August 30, 2019, 10:32am UTC](https://discourse.julialang.org/t/whats-the-official-way-to-keep-track-of-package-test-dependencies-that-are-not-needed-by-a-package/28202/2 "2019-08-30T10:32:58Z")

</div>

Don’t know if it’s “official”, but something like this in the Project.toml is what I use:

```julia
[extras]
Coverage = "a2441757-f6aa-5fb2-8edb-039e3f45d037"
Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"
[targets]
coverage = ["Coverage"]
test = ["Test", "Random"]

```

---

<div class="post-metadata">

### Author: ![Tamas\_Papp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tamas_papp/32/25949_2.png) [@Tamas\_Papp](https://discourse.julialang.org/u/Tamas_Papp)
#### Post date: [August 30, 2019, 10:43am UTC](https://discourse.julialang.org/t/whats-the-official-way-to-keep-track-of-package-test-dependencies-that-are-not-needed-by-a-package/28202/3 "2019-08-30T10:43:48Z")

</div>

This is the recommended way, documented here:

[https://julialang.github.io/Pkg.jl/dev/creating-packages/#Test-specific-dependencies-in-Julia-1.0-and-1.1-1](https://julialang.github.io/Pkg.jl/dev/creating-packages/#Test-specific-dependencies-in-Julia-1.0-and-1.1-1)

but note

[https://julialang.github.io/Pkg.jl/dev/creating-packages/#Test-specific-dependencies-in-Julia-1.2-and-above-1](https://julialang.github.io/Pkg.jl/dev/creating-packages/#Test-specific-dependencies-in-Julia-1.2-and-above-1)
