MovaTesting class abstract final

Switches createMova() to MovaTestKernels for the current test, so widgets that build their player through it (MovaView, or your own code) can be pumped without MediaKit.ensureInitialized().

在当前测试里把 createMova() 切换为使用 MovaTestKernel,让经由它构建播放器的 组件(MovaView 或你自己的代码)无需 MediaKit.ensureInitialized() 即可 pump。

Example / 示例:

setUp(MovaTesting.useTestKernels);
tearDown(MovaTesting.reset);

Properties

hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Properties

active → bool
Whether useTestKernels is currently installed.
no setter
kernels → List<MovaTestKernel>
Kernels created since useTestKernels, oldest first.
no setter
lastKernel → MovaTestKernel?
The most recently created kernel, or null if none yet.
no setter

Static Methods

reset() → void
Uninstalls and forgets every kernel.
useTestKernels([MovaTestKernel factory()?]) → void
While installed, createMova() builds Mova(kernel: factory()) with no-op platform ports and a memory-only thumbnail cache; an explicitly passed kernel:/port still wins.