STAR
Cal STAR — firmware, DAQ server, and engine design
Loading...
Searching...
No Matches
test_results_csv Namespace Reference

Functions

 test_numbers_print_as_javascript_prints_them (value, expected)
 test_csv_shape ()
 _client (session)
 test_endpoint_serves_each_layer_and_refuses_without_results ()

Variables

list NODE

Detailed Description

Layer 2/3 pressure curves as CSV, written by the backend (GET /api/optimizer/layer{2,3}/results.csv).

This file used to be built in the browser. The format has to stay what the browser
wrote, including JavaScript's way of printing numbers, so the expected strings
below are what Node's ``String(n)`` gives for each value (recorded from Node, not
from the code under test).

Function Documentation

◆ _client()

test_results_csv._client ( session)
protected

◆ test_csv_shape()

test_results_csv.test_csv_shape ( )

Definition at line 36 of file test_results_csv.py.

◆ test_endpoint_serves_each_layer_and_refuses_without_results()

test_results_csv.test_endpoint_serves_each_layer_and_refuses_without_results ( )

Definition at line 54 of file test_results_csv.py.

References _client().

◆ test_numbers_print_as_javascript_prints_them()

test_results_csv.test_numbers_print_as_javascript_prints_them ( value,
expected )

Definition at line 32 of file test_results_csv.py.

Variable Documentation

◆ NODE

list test_results_csv.NODE
Initial value:
1= [
2 (5, "5"), (5.0, "5"), (5.5, "5.5"), (0.1, "0.1"), (1e-7, "1e-7"), (1.5e-7, "1.5e-7"),
3 (1e21, "1e+21"), (1.234e22, "1.234e+22"), (123456789012345680000, "123456789012345680000"),
4 (2.5e-6, "0.0000025"), (101325.25, "101325.25"), (1e16, "10000000000000000"),
5 (3.0000000000000004, "3.0000000000000004"), (-0.000001, "-0.000001"), (-42, "-42"),
6 (1e-300, "1e-300"), (6894757.293168361, "6894757.293168361"), (0, "0"),
7]

Definition at line 22 of file test_results_csv.py.