Skip to content

Commit 71aa513

Browse files
authored
Temporarily ignore readme code snippets from getting compiled (#72)
1 parent 39a763e commit 71aa513

File tree

1 file changed

+13
-13
lines changed

1 file changed

+13
-13
lines changed

README.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ mpesa = { git = "https://github.com/collinsmuriuki/mpesa-rust", default_features
3737

3838
In your lib or binary crate:
3939

40-
```rust,no_run
40+
```rust,ignore
4141
use mpesa::Mpesa;
4242
```
4343

@@ -52,7 +52,7 @@ read the docs [here](https://developer.safaricom.co.ke/docs?javascript#going-liv
5252

5353
These are the following ways you can instantiate `Mpesa`:
5454

55-
```rust,no_run
55+
```rust,ignore
5656
use mpesa::{Mpesa, Environment};
5757
5858
let client = Mpesa::new(
@@ -67,7 +67,7 @@ assert!(client.is_connected().await)
6767
Since the `Environment` enum implements `FromStr` and `TryFrom` for `String` and `&str` types, you can call `Environment::from_str` or `Environment::try_from` to create an `Environment` type. This is ideal if the environment values are
6868
stored in a `.env` or any other configuration file:
6969

70-
```rust,no_run
70+
```rust,ignore
7171
use mpesa::{Mpesa, Environment};
7272
use std::str::FromStr;
7373
use std::convert::TryFrom;
@@ -101,7 +101,7 @@ This trait allows you to create your own type to pass to the `environment` param
101101

102102
See the example below (and [here](./src/environment.rs) so see how the trait is implemented for the `Environment` enum):
103103

104-
```rust,no_run
104+
```rust,ignore
105105
use mpesa::{Mpesa, ApiEnvironment};
106106
use std::str::FromStr;
107107
use std::convert::TryFrom;
@@ -132,7 +132,7 @@ let client: Mpesa<MyCustomEnvironment> = Mpesa::new(
132132
If you intend to use in production, you will need to call a the `set_initiator_password` method from `Mpesa` after initially
133133
creating the client. Here you provide your initiator password, which overrides the default password used in sandbox `"Safcom496!"`:
134134

135-
```rust,no_run
135+
```rust,ignore
136136
use mpesa::Mpesa;
137137
138138
let client = Mpesa::new(
@@ -152,7 +152,7 @@ The following services are currently available from the `Mpesa` client as method
152152

153153
- B2C
154154

155-
```rust,no_run
155+
```rust,ignore
156156
let response = client
157157
.b2c("testapi496")
158158
.party_a("600496")
@@ -167,7 +167,7 @@ assert!(response.is_ok())
167167

168168
- B2B
169169

170-
```rust,no_run
170+
```rust,ignore
171171
let response = client
172172
.b2b("testapi496")
173173
.party_a("600496")
@@ -183,7 +183,7 @@ assert!(response.is_ok())
183183

184184
- C2B Register
185185

186-
```rust,no_run
186+
```rust,ignore
187187
let response = client
188188
.c2b_register()
189189
.short_code("600496")
@@ -196,7 +196,7 @@ assert!(response.is_ok())
196196

197197
- C2B Simulate
198198

199-
```rust,no_run
199+
```rust,ignore
200200
let response = client
201201
.c2b_simulate()
202202
.short_code("600496")
@@ -209,7 +209,7 @@ assert!(response.is_ok())
209209

210210
- Account Balance
211211

212-
```rust,no_run
212+
```rust,ignore
213213
let response = client
214214
.account_balance("testapi496")
215215
.result_url("https://testdomain.com/ok")
@@ -222,7 +222,7 @@ assert!(response.is_ok())
222222

223223
- Mpesa Express Request / STK push / Lipa na M-PESA online
224224

225-
```rust,no_run
225+
```rust,ignore
226226
let response = client
227227
.express_request("174379")
228228
.phone_number("254708374149")
@@ -235,7 +235,7 @@ assert!(response.is_ok())
235235

236236
- Transaction Reversal:
237237

238-
```rust,no_run
238+
```rust,ignore
239239
let response = client
240240
.transaction_reversal("testapi496")
241241
.result_url("https://testdomain.com/ok")
@@ -251,7 +251,7 @@ assert!(response.is_ok())
251251

252252
- Transaction Status
253253

254-
```rust,no_run
254+
```rust,ignore
255255
let response = client
256256
.transaction_status("testapi496")
257257
.result_url("https://testdomain.com/ok")

0 commit comments

Comments
 (0)