From 081240c60120d9fd8c7564fd13e1d87d761f7a46 Mon Sep 17 00:00:00 2001 From: Hirotaka Aoki <113173839+aoki-h-jp@users.noreply.github.com> Date: Fri, 25 Aug 2023 18:45:46 +0900 Subject: [PATCH 1/9] Initial commit --- .github/workflows/pytest.yaml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 .github/workflows/pytest.yaml diff --git a/.github/workflows/pytest.yaml b/.github/workflows/pytest.yaml new file mode 100644 index 0000000..82cac17 --- /dev/null +++ b/.github/workflows/pytest.yaml @@ -0,0 +1,19 @@ +name: pytest + +on: [push] + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Install pipenv + run: pipx install pipenv + - name: Set up pipenv + uses: actions/setup-python@v2 + with: + python-version: "3.9" + cache: "pipenv" + - run: pipenv install + - name: Test with pytest + run: pipenv run pytest -v -s \ No newline at end of file From 25997eb82df20dba0f65f2b0c50ff0f65426c69c Mon Sep 17 00:00:00 2001 From: Hirotaka Aoki <113173839+aoki-h-jp@users.noreply.github.com> Date: Fri, 25 Aug 2023 18:50:27 +0900 Subject: [PATCH 2/9] Initial commit --- .github/workflows/pytest.yaml | 45 ++++++++++++++++++++++++----------- 1 file changed, 31 insertions(+), 14 deletions(-) diff --git a/.github/workflows/pytest.yaml b/.github/workflows/pytest.yaml index 82cac17..34ae8a7 100644 --- a/.github/workflows/pytest.yaml +++ b/.github/workflows/pytest.yaml @@ -1,19 +1,36 @@ -name: pytest +name: Run pytest on all branches -on: [push] +on: + push: + branches: + - '*' # 全てのブランチに対して実行する jobs: - build: + test: runs-on: ubuntu-latest + steps: - - uses: actions/checkout@v2 - - name: Install pipenv - run: pipx install pipenv - - name: Set up pipenv - uses: actions/setup-python@v2 - with: - python-version: "3.9" - cache: "pipenv" - - run: pipenv install - - name: Test with pytest - run: pipenv run pytest -v -s \ No newline at end of file + - name: Checkout repository + uses: actions/checkout@v2 + + - name: Set up Python + uses: actions/setup-python@v2 + with: + python-version: 3.9 # 使用するPythonのバージョンを指定してください + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install pipenv + pipenv install --dev # Pipenvを使用して依存関係をインストール + + - name: Run pytest + run: | + pipenv run pytest -v -s # pytestを実行するコマンドを指定 + + - name: Upload test results + uses: actions/upload-artifact@v2 + with: + name: test-results + path: | + pytest-results.xml # テスト結果のファイル名を適宜変更 From 2f094ac649a74ebf3fea558f07c6c87a6c7874ee Mon Sep 17 00:00:00 2001 From: Hirotaka Aoki <113173839+aoki-h-jp@users.noreply.github.com> Date: Fri, 25 Aug 2023 18:52:22 +0900 Subject: [PATCH 3/9] Initial commit --- .github/workflows/pytest.yaml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/.github/workflows/pytest.yaml b/.github/workflows/pytest.yaml index 34ae8a7..5004420 100644 --- a/.github/workflows/pytest.yaml +++ b/.github/workflows/pytest.yaml @@ -1,9 +1,6 @@ name: Run pytest on all branches -on: - push: - branches: - - '*' # 全てのブランチに対して実行する +on: push jobs: test: From 11ddbf64c5a68e848575e51f48eddfb14bcd3852 Mon Sep 17 00:00:00 2001 From: Hirotaka Aoki <113173839+aoki-h-jp@users.noreply.github.com> Date: Fri, 25 Aug 2023 18:55:56 +0900 Subject: [PATCH 4/9] fix import --- tests/test_aggtrades.py | 2 +- tests/test_bookdepth.py | 2 +- tests/test_bookticker.py | 2 +- tests/test_bvolindex.py | 2 +- tests/test_eohsummary.py | 2 +- tests/test_fundingrate.py | 2 +- tests/test_indexpriceklines.py | 2 +- tests/test_klines.py | 2 +- tests/test_liquidationsnapshot.py | 2 +- tests/test_markpriceklines.py | 2 +- tests/test_metrics.py | 2 +- tests/test_premiumindexklines.py | 2 +- tests/test_trades.py | 2 +- 13 files changed, 13 insertions(+), 13 deletions(-) diff --git a/tests/test_aggtrades.py b/tests/test_aggtrades.py index 9ad287b..d5ae8e7 100644 --- a/tests/test_aggtrades.py +++ b/tests/test_aggtrades.py @@ -5,7 +5,7 @@ import pytest # import my libraries -from downloader.downloader import * +from downloader import BinanceBulkDownloader def dynamic_aggtrades_test_params(): diff --git a/tests/test_bookdepth.py b/tests/test_bookdepth.py index ca17bc3..178461a 100644 --- a/tests/test_bookdepth.py +++ b/tests/test_bookdepth.py @@ -5,7 +5,7 @@ import pytest # import my libraries -from downloader.downloader import * +from downloader import BinanceBulkDownloader def dynamic_bookdepth_test_params(): diff --git a/tests/test_bookticker.py b/tests/test_bookticker.py index 55c5f98..cbf0911 100644 --- a/tests/test_bookticker.py +++ b/tests/test_bookticker.py @@ -5,7 +5,7 @@ import pytest # import my libraries -from downloader.downloader import * +from downloader import BinanceBulkDownloader def dynamic_bookticker_test_params(): diff --git a/tests/test_bvolindex.py b/tests/test_bvolindex.py index 136801b..a8a5c5c 100644 --- a/tests/test_bvolindex.py +++ b/tests/test_bvolindex.py @@ -5,7 +5,7 @@ import pytest # import my libraries -from downloader.downloader import * +from downloader import BinanceBulkDownloader def dynamic_bvolindex_test_params(): diff --git a/tests/test_eohsummary.py b/tests/test_eohsummary.py index 993733d..3f28b8f 100644 --- a/tests/test_eohsummary.py +++ b/tests/test_eohsummary.py @@ -5,7 +5,7 @@ import pytest # import my libraries -from downloader.downloader import * +from downloader import BinanceBulkDownloader def dynamic_eohsummary_test_params(): diff --git a/tests/test_fundingrate.py b/tests/test_fundingrate.py index 23894e4..2ef6b88 100644 --- a/tests/test_fundingrate.py +++ b/tests/test_fundingrate.py @@ -5,7 +5,7 @@ import pytest # import my libraries -from downloader.downloader import * +from downloader import BinanceBulkDownloader def dynamic_fundingrate_test_params(): diff --git a/tests/test_indexpriceklines.py b/tests/test_indexpriceklines.py index 2777262..8846aa4 100644 --- a/tests/test_indexpriceklines.py +++ b/tests/test_indexpriceklines.py @@ -5,7 +5,7 @@ import pytest # import my libraries -from downloader.downloader import * +from downloader import BinanceBulkDownloader def dynamic_indexpriceklines_test_params(): diff --git a/tests/test_klines.py b/tests/test_klines.py index fe13b9c..aef53da 100644 --- a/tests/test_klines.py +++ b/tests/test_klines.py @@ -5,7 +5,7 @@ import pytest # import my libraries -from downloader.downloader import * +from downloader import BinanceBulkDownloader def dynamic_klines_test_params(): diff --git a/tests/test_liquidationsnapshot.py b/tests/test_liquidationsnapshot.py index b31bba4..9824d50 100644 --- a/tests/test_liquidationsnapshot.py +++ b/tests/test_liquidationsnapshot.py @@ -5,7 +5,7 @@ import pytest # import my libraries -from downloader.downloader import * +from downloader import BinanceBulkDownloader def dynamic_liquidationsnapshot_test_params(): diff --git a/tests/test_markpriceklines.py b/tests/test_markpriceklines.py index 83bc6c0..334b322 100644 --- a/tests/test_markpriceklines.py +++ b/tests/test_markpriceklines.py @@ -5,7 +5,7 @@ import pytest # import my libraries -from downloader.downloader import * +from downloader import BinanceBulkDownloader def dynamic_markpriceklines_test_params(): diff --git a/tests/test_metrics.py b/tests/test_metrics.py index b3f1d81..bfd924a 100644 --- a/tests/test_metrics.py +++ b/tests/test_metrics.py @@ -5,7 +5,7 @@ import pytest # import my libraries -from downloader.downloader import * +from downloader import BinanceBulkDownloader def dynamic_metrics_test_params(): diff --git a/tests/test_premiumindexklines.py b/tests/test_premiumindexklines.py index 804bace..50f376d 100644 --- a/tests/test_premiumindexklines.py +++ b/tests/test_premiumindexklines.py @@ -5,7 +5,7 @@ import pytest # import my libraries -from downloader.downloader import * +from downloader import BinanceBulkDownloader def dynamic_premiumindexklines_test_params(): diff --git a/tests/test_trades.py b/tests/test_trades.py index 756e067..2c1739e 100644 --- a/tests/test_trades.py +++ b/tests/test_trades.py @@ -5,7 +5,7 @@ import pytest # import my libraries -from downloader.downloader import * +from downloader import BinanceBulkDownloader def dynamic_trades_test_params(): From d23d9a509717930c6e2b410534fdb0837f38eae8 Mon Sep 17 00:00:00 2001 From: Hirotaka Aoki <113173839+aoki-h-jp@users.noreply.github.com> Date: Fri, 25 Aug 2023 18:58:49 +0900 Subject: [PATCH 5/9] Initial commit --- .github/workflows/pytest.yaml | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/.github/workflows/pytest.yaml b/.github/workflows/pytest.yaml index 5004420..f5c99b8 100644 --- a/.github/workflows/pytest.yaml +++ b/.github/workflows/pytest.yaml @@ -19,15 +19,9 @@ jobs: run: | python -m pip install --upgrade pip pip install pipenv + pip install git+https://github.com/aoki-h-jp/binance-bulk-downloader pipenv install --dev # Pipenvを使用して依存関係をインストール - name: Run pytest run: | pipenv run pytest -v -s # pytestを実行するコマンドを指定 - - - name: Upload test results - uses: actions/upload-artifact@v2 - with: - name: test-results - path: | - pytest-results.xml # テスト結果のファイル名を適宜変更 From a3150a1b495245ff4a53a3ecfbdb216ff91049d8 Mon Sep 17 00:00:00 2001 From: Hirotaka Aoki <113173839+aoki-h-jp@users.noreply.github.com> Date: Fri, 25 Aug 2023 18:59:26 +0900 Subject: [PATCH 6/9] Add pytest badge --- README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/README.md b/README.md index 762a700..2bfda1a 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,7 @@ # binance-bulk-downloader [![Python 3.11](https://img.shields.io/badge/python-3.11-blue.svg)](https://www.python.org/downloads/release/python-3110//) [![Format code](https://github.com/aoki-h-jp/binance-bulk-downloader/actions/workflows/Formatter.yml/badge.svg?branch=main)](https://github.com/aoki-h-jp/binance-bulk-downloader/actions/workflows/Formatter.yml) +[![pytest](https://github.com/aoki-h-jp/binance-bulk-downloader/actions/workflows/pytest.yaml/badge.svg)](https://github.com/aoki-h-jp/binance-bulk-downloader/actions/workflows/pytest.yaml) ## Python library for bulk downloading Binance historical data A Python library to efficiently and concurrently download historical data files from Binance. Supports all asset types (spot, USDT-M, COIN-M, options) and all data frequencies. From 38692460192ea08cb2ae51c64805321999b3d36c Mon Sep 17 00:00:00 2001 From: Hirotaka Aoki <113173839+aoki-h-jp@users.noreply.github.com> Date: Fri, 25 Aug 2023 19:03:13 +0900 Subject: [PATCH 7/9] Initial commit --- tests/__init__.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 tests/__init__.py diff --git a/tests/__init__.py b/tests/__init__.py new file mode 100644 index 0000000..91e6cc2 --- /dev/null +++ b/tests/__init__.py @@ -0,0 +1,13 @@ +import test_aggtrades +import test_bookdepth +import test_bookticker +import test_bvolindex +import test_eohsummary +import test_fundingrate +import test_indexpriceklines +import test_klines +import test_liquidationsnapshot +import test_markpriceklines +import test_metrics +import test_premiumindexklines +import test_trades From d0eae10e44696a3e60bdd4ea8622f030574ac1d9 Mon Sep 17 00:00:00 2001 From: Hirotaka Aoki <113173839+aoki-h-jp@users.noreply.github.com> Date: Fri, 25 Aug 2023 19:04:56 +0900 Subject: [PATCH 8/9] Initial commit --- tests/__init__.py | 13 ------------- 1 file changed, 13 deletions(-) diff --git a/tests/__init__.py b/tests/__init__.py index 91e6cc2..e69de29 100644 --- a/tests/__init__.py +++ b/tests/__init__.py @@ -1,13 +0,0 @@ -import test_aggtrades -import test_bookdepth -import test_bookticker -import test_bvolindex -import test_eohsummary -import test_fundingrate -import test_indexpriceklines -import test_klines -import test_liquidationsnapshot -import test_markpriceklines -import test_metrics -import test_premiumindexklines -import test_trades From ec05fb36e255d55edca1b735d9a903821f4098ab Mon Sep 17 00:00:00 2001 From: Hirotaka Aoki <113173839+aoki-h-jp@users.noreply.github.com> Date: Fri, 25 Aug 2023 19:07:33 +0900 Subject: [PATCH 9/9] Initial commit --- example/__init__.py | 0 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 example/__init__.py diff --git a/example/__init__.py b/example/__init__.py new file mode 100644 index 0000000..e69de29