Skip to content

Commit 2523de1

Browse files
committed
Merge branch 'master' of github.com:ccxt/php-binance-api
2 parents 55ff8c8 + 142847f commit 2523de1

File tree

8 files changed

+6985
-253
lines changed

8 files changed

+6985
-253
lines changed

.github/workflows/php.yml

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: PHP Composer
2+
3+
on:
4+
push:
5+
branches: [ "master" ]
6+
pull_request:
7+
branches: [ "master" ]
8+
9+
permissions:
10+
contents: read
11+
12+
jobs:
13+
build:
14+
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- uses: actions/checkout@v4
19+
20+
- name: Validate composer.json and composer.lock
21+
run: composer validate --strict
22+
23+
- name: Cache Composer packages
24+
id: composer-cache
25+
uses: actions/cache@v3
26+
with:
27+
path: vendor
28+
key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }}
29+
restore-keys: |
30+
${{ runner.os }}-php-
31+
32+
- name: Install dependencies
33+
run: composer install --prefer-dist --no-progress
34+
- name: Static Tests
35+
run: composer test
36+
- name: Live Tests
37+
run: composer live-tests
38+
39+
# Add a test script to composer.json, for instance: "test": "vendor/bin/phpunit"
40+
# Docs: https://getcomposer.org/doc/articles/scripts.md
41+
42+
# - name: Run test suite
43+
# run: composer run-script test

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
composer.lock
1+
# composer.lock
22
vendor**
33
.buildpath
44
.project

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/683459a5a71c4875956cf23078a0c39b)](https://www.codacy.com/app/dmzoneill/php-binance-api?utm_source=github.com&utm_medium=referral&utm_content=jaggedsoft/php-binance-api&utm_campaign=Badge_Grade)
1313
-->
1414
# PHP Binance API
15-
This project is designed to help you make your own projects that interact with [Binance](https://accounts.binance.com/register?ref=PGDFCE46). You can stream candlestick chart data, market depth, or use other advanced features such as setting stop losses and iceberg orders. This project seeks to have complete API coverage including WebSockets.
15+
This project is designed to help you make your own projects that interact with [Binance](https://accounts.binance.com/register?ref=PGDFCE46). You can stream candlestick chart data, market depth, or use other advanced features such as setting stop losses and iceberg orders. This project seeks to have complete API coverage (spot and futures) including WebSockets.
1616

1717
#### Installation
1818
```

composer.json

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,14 @@
88
"url": "https://github.com/jaggedsoft/php-binance-api"
99
}],
1010
"require": {
11-
"php": ">=7.0",
11+
"php": ">=7.4",
1212
"ext-curl": "*",
1313
"ratchet/pawl": "^0.4.0",
1414
"react/socket": "^1.0 || ^0.8 || ^0.7",
1515
"ratchet/rfc6455": "^0.3"
1616
},
1717
"require-dev": {
18-
"phpunit/phpunit": "~6",
18+
"phpunit/phpunit": "^12.0",
1919
"codacy/coverage": "dev-master"
2020
},
2121
"config": {
@@ -27,5 +27,9 @@
2727
"php-binance-api.php",
2828
"php-binance-api-rate-limiter.php"
2929
]
30+
},
31+
"scripts": {
32+
"test": "phpunit tests/BinanceStaticTests.php",
33+
"live-tests": "phpunit tests/BinanceLiveTests.php"
3034
}
3135
}

0 commit comments

Comments
 (0)