Rename sonar to flipper in the docs

Summary: Sonar->Flipper

Reviewed By: passy

Differential Revision: D10032191

fbshipit-source-id: 5e5230a02e34b9d1c7c355701daef984dc779f35
This commit is contained in:
Pritesh Nandgaonkar
2018-09-26 03:58:20 -07:00
committed by Facebook Github Bot
parent 588d61efc6
commit 3699a0667a
8 changed files with 33 additions and 33 deletions

View File

@@ -50,10 +50,10 @@ public void myTest() {
## C++
Start by creating your first test file in this directory `MySonarPluginTests.cpp` and import the testing utilities from `//xplat/sonar-client:FlipperTestLib`. These utilities mock out core pieces of the communication channel so that you can test your plugin in isolation.
Start by creating your first test file in this directory `MyFlipperPluginTests.cpp` and import the testing utilities from `xplat//sonar/xplat:FlipperTestLib`. These utilities mock out core pieces of the communication channel so that you can test your plugin in isolation.
```
#include <MySonarPlugin/MySonarPlugin.h>
#include <MyFlipperPlugin/MyFlipperPlugin.h>
#include <FlipperTestLib/FlipperConnectionMock.h>
#include <FlipperTestLib/FlipperResponderMock.h>
@@ -64,7 +64,7 @@ namespace facebook {
namespace flipper {
namespace test {
TEST(MySonarPluginTests, testDummy) {
TEST(MyFlipperPluginTests, testDummy) {
EXPECT_EQ(1 + 1, 2);
}
@@ -76,12 +76,12 @@ TEST(MySonarPluginTests, testDummy) {
Here is a simple test using these mock utilities to create a plugin, send some data, and assert that the result is as expected.
```
TEST(MySonarPluginTests, testDummy) {
TEST(MyFlipperPluginTests, testDummy) {
std::vector<folly::dynamic> successfulResponses;
auto responder = std::make_unique<FlipperResponderMock>(&successfulResponses);
auto conn = std::make_shared<FlipperConnectionMock>();
MySonarPlugin plugin;
MyFlipperPlugin plugin;
plugin.didConnect(conn);
folly::dynamic message = folly::dynamic::object("param1", "hello");