Skip to content
This repository was archived by the owner on Jun 23, 2022. It is now read-only.

Commit e0bc349

Browse files
committed
Add CI
1 parent 627ea2d commit e0bc349

File tree

4 files changed

+49
-8
lines changed

4 files changed

+49
-8
lines changed

.github/workflows/push-check.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Push Check
2+
3+
on: [push]
4+
5+
jobs:
6+
msrv:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v1
10+
with:
11+
submodules: recursive
12+
- uses: actions-rs/toolchain@v1
13+
with:
14+
toolchain: 1.36.0
15+
override: true
16+
- uses: actions-rs/cargo@v1
17+
with:
18+
command: build
19+
args: --verbose
20+
build_and_test:
21+
runs-on: ${{ matrix.os }}
22+
strategy:
23+
matrix:
24+
os: [ubuntu-latest, windows-latest, macos-latest]
25+
steps:
26+
- uses: actions/checkout@v1
27+
with:
28+
submodules: recursive
29+
- uses: actions-rs/toolchain@v1
30+
with:
31+
toolchain: stable
32+
override: true
33+
- uses: actions-rs/cargo@v1
34+
with:
35+
command: test
36+
args: --verbose
37+
- uses: actions-rs/cargo@v1
38+
with:
39+
command: test
40+
args: --verbose --no-default-features --lib

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,4 +27,4 @@ image_encoder = ["image"]
2727
gif_backend = ["gif", "image_encoder"]
2828

2929
[dev-dependencies]
30-
plotters = {path = "../plotters", default_features = false, features = ["ttf"]}
30+
plotters = {version = "^0.3.0", default_features = false, features = ["ttf"]}

src/bitmap.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1009,6 +1009,7 @@ impl<P: PixelFormat> Drop for BitMapBackend<'_, P> {
10091009
#[test]
10101010
fn test_bitmap_backend() {
10111011
use plotters::prelude::*;
1012+
10121013
let mut buffer = vec![0; 10 * 10 * 3];
10131014

10141015
{
@@ -1411,7 +1412,7 @@ mod test {
14111412
let mut chart = ChartBuilder::on(&root)
14121413
.caption("This is a test", ("sans-serif", 20))
14131414
.set_all_label_area_size(40)
1414-
.build_ranged(0..10, 0..10)
1415+
.build_cartesian_2d(0..10, 0..10)
14151416
.unwrap();
14161417

14171418
chart
@@ -1447,7 +1448,7 @@ mod test {
14471448
let mut chart = ChartBuilder::on(&root)
14481449
.caption("All anchor point positions", ("sans-serif", 20))
14491450
.set_all_label_area_size(40)
1450-
.build_ranged(0..100, 0..50)
1451+
.build_cartesian_2d(0..100, 0..50)
14511452
.unwrap();
14521453

14531454
chart
@@ -1532,7 +1533,7 @@ mod test {
15321533
let mut chart = ChartBuilder::on(&root)
15331534
.caption("All series label positions", ("sans-serif", 20))
15341535
.set_all_label_area_size(40)
1535-
.build_ranged(0..50, 0..50)
1536+
.build_cartesian_2d(0..50, 0..50)
15361537
.unwrap();
15371538

15381539
chart

src/lib.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
/*!
2-
The Plotters bitmap backend.
3-
4-
The plotters bitmap backend allows you to render images by Plotters into bitmap.
5-
You can either generate image file(PNG, JPG, GIF, etc) or rendering the bitmap within internal buffer (for example for framebuffer, etc).
2+
The Plotters bitmap backend.
3+
4+
The plotters bitmap backend allows you to render images by Plotters into bitmap.
5+
You can either generate image file(PNG, JPG, GIF, etc) or rendering the bitmap within internal buffer (for example for framebuffer, etc).
66
77
See the documentation for [BitMapBackend](struct.BitMapBackend.html) for more details.
88
*/

0 commit comments

Comments
 (0)