File: development.rst

package info (click to toggle)
python-asv-bench-memray 0.1.2-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 148 kB
  • sloc: python: 53; makefile: 7
file content (34 lines) | stat: -rw-r--r-- 940 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
Development
===========

During development, one needs to pass a relative path:

.. code:: json

   "matrix": {
       "req": {
           "asv_bench_memray": ["../asv_bench_memray"]
       },
   },

Also it may be necessary to cleanup older environments and explicitly
point to an instance of ``asv_runner``:

.. code:: sh

   rm -rf .asv && ASV_RUNNER_PATH="../asv_runner" asv run --bench sum

Personally I keep benchmarks for testing at an `experiments
repo <https://github.com/HaoZeke/asv_experiments>`__, but any local test
will do.

Conventions
-----------

Like all externally defined benchmark plugins for ``asv``, this has a strict hierarchy:

- The package name begins with ``asv_bench``.
- Benchmarks are defined in a ``benchmarks`` folder under the package module.
- Each exported new benchmark type has the ``export_as_benchmark = [NAMEBenchmark]`` attribute.

For more conventions, follow the documentation of ``asv_runner``.