···170170})
171171```
172172173173+### meta <Version>4.1.0</Version> {#meta}
174174+175175+- **Type:** `TaskMeta`
176176+177177+Attaches custom [metadata](/api/advanced/metadata) available in reporters.
178178+179179+::: warning
180180+Vitest merges top-level properties inherited from suites or tags. However, it does not perform a deep merge of nested objects.
181181+182182+```ts
183183+import { describe, test } from 'vitest'
184184+185185+describe(
186186+ 'nested meta',
187187+ {
188188+ meta: {
189189+ nested: { object: true, array: false },
190190+ },
191191+ },
192192+ () => {
193193+ test(
194194+ 'overrides part of meta',
195195+ {
196196+ meta: {
197197+ nested: { object: false }
198198+ },
199199+ },
200200+ ({ task }) => {
201201+ // task.meta === { nested: { object: false } }
202202+ // notice array got lost because "nested" object was overriden
203203+ }
204204+ )
205205+ }
206206+)
207207+```
208208+209209+Prefer using non-nested meta, if possible.
210210+:::
211211+173212### concurrent
174213175214- **Type:** `boolean`
+7-1
docs/api/advanced/test-case.md
···143143})
144144```
145145146146-If the test did not finish running yet, the meta will be an empty object.
146146+If the test did not finish running yet, the meta will be an empty object, unless it has static meta:
147147+148148+```ts
149149+test('the validation works correctly', { meta: { decorated: true } })
150150+```
151151+152152+Since Vitest 4.1, Vitest inherits [`meta`](/api/advanced/test-suite#meta) property defined on the [suite](/api/advanced/test-suite).
147153148154## result
149155
+8-7
docs/api/advanced/test-suite.md
···198198function meta(): TaskMeta
199199```
200200201201-Custom [metadata](/api/advanced/metadata) that was attached to the suite during its execution or collection. The meta can be attached by assigning a property to the `suite.meta` object during a test run:
201201+Custom [metadata](/api/advanced/metadata) that was attached to the suite during its execution or collection. Since Vitest 4.1, the meta can be attached by providing a `meta` object during test collection:
202202203203-```ts {7,12}
203203+```ts {7,10}
204204import { describe, test, TestRunner } from 'vitest'
205205206206-describe('the validation works correctly', () => {
207207- // assign "decorated" during collection
208208- const { suite } = TestRunner.getCurrentSuite()
209209- suite!.meta.decorated = true
210210-206206+describe('the validation works correctly', { meta: { decorated: true } }, () => {
211207 test('some test', ({ task }) => {
212208 // assign "decorated" during test run, it will be available
213209 // only in onTestCaseReady hook
214210 task.suite.meta.decorated = false
211211+212212+ // tests inherit suite's metadata
213213+ task.meta.decorated === true
215214 })
216215})
217216```
217217+218218+Note that suite metadata will be inherited by tests since Vitest 4.1.
218219219220:::tip
220221If metadata was attached during collection (outside of the `test` function), then it will be available in [`onTestModuleCollected`](./reporters#ontestmodulecollected) hook in the custom reporter.