@Test
public void insertNodeList(){

    List<Node> nodeList = new ArrayList<>();
    Node node =new Node();
    node.setNodeAddress("https://192.168.12.22");
    node.setDefaultNode(false);
    node.setMainNetworkNode(false);
    node.setChecked(false);
    node.setChainId("103");
    node.setFormatCorrect(false);
    nodeList.add(node);
    Node node2 =new Node();
    node2.setNodeAddress("https://192.168.12.82");
    node2.setDefaultNode(true);
    node2.setMainNetworkNode(true);
    node2.setChecked(false);
    node2.setChainId("103");
    node2.setFormatCorrect(false);
    nodeList.add(node2);
    Node node3 =new Node();
    node3.setNodeAddress("https://192.168.12.182");
    node3.setDefaultNode(true);
    node3.setMainNetworkNode(false);
    node3.setChecked(false);
    node3.setChainId("103");
    node3.setFormatCorrect(false);
    nodeList.add(node3);
    Flowable.fromIterable(nodeList)
            .map(new Function<Node, NodeEntity>() {
                @Override
                public NodeEntity apply(Node node) throws Exception {
                    return node.createNodeInfo();
                }
            }).toList()
            .map(new Function<List<NodeEntity>, Boolean>() {
                @Override
                public Boolean apply(List<NodeEntity> nodeEntities) throws Exception {
                    return nodeEntities.size()> 0;
                }
            }).subscribeOn(Schedulers.io())
            .compose(new SchedulersTransformer())
            .subscribe(new Consumer<Boolean>() {
                @Override
                public void accept(Boolean aBoolean) throws Exception {
                    if (aBoolean.booleanValue()) {
                        System.out.println(R.string.save_node_succeed);
                    }
                }
            }, new Consumer<Throwable>() {
                @Override
                public void accept(Throwable throwable) throws Exception {
                    Log.e("NodesettingsPresenterTest", throwable.getMessage());
                }
            });
}