Skip to content

Commit

Permalink
Fixes the knapsack-ortools-csv test
Browse files Browse the repository at this point in the history
  • Loading branch information
sebastian-quintero committed Apr 26, 2024
1 parent 430a1f5 commit 0341e25
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .nextmv/readme/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ Update the commands:
python readme-extract-commands.py --update
```

Change the configuration for the app (if needed) or add a new one. This is done
in the `workflow-configuration.yml` file.

Update the expectations / re-run the tests:

```bash
Expand Down
16 changes: 16 additions & 0 deletions .nextmv/readme/knapsack-ortools-csv/1.sh.golden
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"result": {
"custom": {
"constraints": 1,
"provider": "SCIP",
"status": "optimal",
"variables": 11
},
"duration": 0.123,
"value": 444.0
},
"run": {
"duration": 0.123
},
"schema": "v1"
}
1 change: 1 addition & 0 deletions .nextmv/readme/main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ func TestGolden(t *testing.T) {
// Define replacements
replacements := []golden.VolatileRegexReplacement{
// Replace "duration": 0.354 with "duration":0.123
{Regex: `duration": \d+\.\d+`, Replacement: `duration": 0.123`},
{Regex: `duration":\d+\.\d+`, Replacement: `duration":0.123`},
// Replace xpress.init(...) with
// xpress.init("path/to/xpress")
Expand Down
6 changes: 6 additions & 0 deletions .nextmv/readme/workflow-configuration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,12 @@ apps:
silent: true
- name: 2.sh
skip: true
- name: knapsack-ortools-csv
scripts:
- name: 0.sh
silent: true
- name: 2.sh
skip: true
- name: knapsack-pyomo
scripts:
- name: 0.sh
Expand Down

0 comments on commit 0341e25

Please sign in to comment.