<p dir="auto">Hi. Today, I tried to work on making test codes for my plugin and I can't make the call to plugin methods in test code. Is there any guideline make test code for plugins?</p>
<div class="highlight highlight-source-dart notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import 'package:flutter/material.dart';
import 'package:flutter_test/flutter_test.dart';
import 'package:flutter_sound/flutter_sound.dart';

import 'package:flutter_sound_example/main.dart';

void main() {
  test('startRecorder', () async {
    FlutterSound flutterSound = new FlutterSound();
    String path = await flutterSound.startRecorder(null);
    print('path: $path');
  });
}
"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s">'package:flutter/material.dart'</span>;
<span class="pl-k">import</span> <span class="pl-s">'package:flutter_test/flutter_test.dart'</span>;
<span class="pl-k">import</span> <span class="pl-s">'package:flutter_sound/flutter_sound.dart'</span>;

<span class="pl-k">import</span> <span class="pl-s">'package:flutter_sound_example/main.dart'</span>;

<span class="pl-k">void</span> <span class="pl-en">main</span>() {
  <span class="pl-en">test</span>(<span class="pl-s">'startRecorder'</span>, () <span class="pl-k">async</span> {
    <span class="pl-c1">FlutterSound</span> flutterSound <span class="pl-k">=</span> <span class="pl-k">new</span> <span class="pl-c1">FlutterSound</span>();
    <span class="pl-c1">String</span> path <span class="pl-k">=</span> <span class="pl-k">await</span> flutterSound.<span class="pl-en">startRecorder</span>(<span class="pl-c1">null</span>);
    <span class="pl-en">print</span>(<span class="pl-s">'path: $<span class="pl-v">path</span>'</span>);
  });
}
</pre></div>
<p dir="auto">Error code below.</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Exception: MissingPluginException(No implementation found for method startRecorder on channel flutter_sound)
  package:flutter_sound/flutter_sound.dart 100:7  FlutterSound.startRecorder
  ===== asynchronous gap ===========================
  dart:async                                      _AsyncAwaitCompleter.completeError
  package:flutter_sound/flutter_sound.dart        FlutterSound.startRecorder
  ===== asynchronous gap ===========================
  dart:async                                      _asyncErrorWrapperHelper
  package:flutter_sound/flutter_sound.dart        FlutterSound.startRecorder
  test/widget_test.dart 28:38                     main.&lt;fn&gt;"><pre class="notranslate"><code class="notranslate">Exception: MissingPluginException(No implementation found for method startRecorder on channel flutter_sound)
  package:flutter_sound/flutter_sound.dart 100:7  FlutterSound.startRecorder
  ===== asynchronous gap ===========================
  dart:async                                      _AsyncAwaitCompleter.completeError
  package:flutter_sound/flutter_sound.dart        FlutterSound.startRecorder
  ===== asynchronous gap ===========================
  dart:async                                      _asyncErrorWrapperHelper
  package:flutter_sound/flutter_sound.dart        FlutterSound.startRecorder
  test/widget_test.dart 28:38                     main.&lt;fn&gt;
</code></pre></div>
<p dir="auto">flutter doctor.</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel dev, v0.5.7, on Mac OS X 10.13.6 17G65, locale en-KR)
[✓] Android toolchain - develop for Android devices (Android SDK 27.0.3)
[✓] iOS toolchain - develop for iOS devices (Xcode 9.4.1)
[✓] Android Studio (version 3.1)
[!] VS Code (version 1.26.1)
[✓] Connected devices (1 available)

! Doctor found issues in 1 category."><pre class="notranslate"><code class="notranslate">Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel dev, v0.5.7, on Mac OS X 10.13.6 17G65, locale en-KR)
[✓] Android toolchain - develop for Android devices (Android SDK 27.0.3)
[✓] iOS toolchain - develop for iOS devices (Xcode 9.4.1)
[✓] Android Studio (version 3.1)
[!] VS Code (version 1.26.1)
[✓] Connected devices (1 available)

! Doctor found issues in 1 category.
</code></pre></div>
<p dir="auto">Currently our plugin template and plugin docs have no recommendation for how to test a plugin. We should probably figure out what to do here.</p>