Skip to content

Commit

Permalink
✅ test(test_pmp_iv.py): Update to #25, #26, #29
Browse files Browse the repository at this point in the history
  • Loading branch information
MauronMP committed Nov 15, 2022
1 parent 0dfc4fc commit 8721910
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 61 deletions.
1 change: 0 additions & 1 deletion iv.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,4 @@ automatizar:
orden: invoke

test:
- tests/test_Jupyter.py
- tests/test_pmp_iv.py
Binary file removed output/diagramaDispersion/Viento.png
Binary file not shown.
37 changes: 0 additions & 37 deletions pmp_iv/segmentacionCSV/Datos.py

This file was deleted.

22 changes: 0 additions & 22 deletions tests/test_Datos.py

This file was deleted.

14 changes: 13 additions & 1 deletion tests/test_pmp_iv.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,9 @@
import pmp_iv.enums.day
import pmp_iv.enums.month
import pmp_iv.models.coordenada

from pmp_iv.forest_prediction.eda import *
from pmp_iv.forest_prediction.model_building import *
import pmp_iv.enums.regression_algorithm
from hamcrest import *

def test_syntaxis():
Expand All @@ -18,5 +20,15 @@ def test_Constructores():
assert_that(pmp_iv.models.fecha.Fecha(pmp_iv.enums.month.Month.julio,pmp_iv.enums.day.Day.L).mes,same_instance(pmp_iv.enums.month.Month.julio))
assert_that(pmp_iv.models.estado.Estado(10,10,9,3,200).temperature, less_than_or_equal_to(50))

def test_month_filter():
filtrado_mes = EDA().by_date_property('aug','mon')
for i in range(len(filtrado_mes)):
assert_that(filtrado_mes[i],has_items('aug','mon'))

def test_wind_filter():
filtrado_mes_viento = EDA().by_date_property('aug','mon','wind')
for i in range(len(filtrado_mes_viento)):
assert_that(float(filtrado_mes_viento[i][4]),less_than_or_equal_to(10) and greater_than(0))

def test_regression_selected():
assert_that(model_building().get_best_results(),anything(Regression_algorithm._member_names_))

0 comments on commit 8721910

Please sign in to comment.