Skip to content

Commit

Permalink
t: add max_nodes, max_cores fields to payload data
Browse files Browse the repository at this point in the history
Problem: t1005 and t1012 create JSON payloads to be sent to the plugin,
but these payloads don't contain max_cores or max_nodes information
per-association.

Add this information to the payloads sent to the plugin in t1005 and
t1012.
  • Loading branch information
cmoussa1 committed Jan 21, 2025
1 parent dab1d7a commit 57c782e
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 8 deletions.
24 changes: 18 additions & 6 deletions t/t1005-max-jobs-limits.t
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,9 @@ test_expect_success 'create fake_user.json' '
"queues": "",
"active": 1,
"projects": "*",
"def_project": "*"
"def_project": "*",
"max_nodes": 2147483647,
"max_cores": 2147483647
},
{
"userid": 5011,
Expand All @@ -54,7 +56,9 @@ test_expect_success 'create fake_user.json' '
"queues": "",
"active": 1,
"projects": "*",
"def_project": "*"
"def_project": "*",
"max_nodes": 2147483647,
"max_cores": 2147483647
}
]
}
Expand Down Expand Up @@ -152,7 +156,9 @@ test_expect_success 'increase the max jobs count of the user' '
"queues": "",
"active": 1,
"projects": "*",
"def_project": "*"
"def_project": "*",
"max_nodes": 2147483647,
"max_cores": 2147483647
}
]
}
Expand Down Expand Up @@ -204,7 +210,9 @@ test_expect_success 'update max_active_jobs limit' '
"queues": "",
"active": 1,
"projects": "*",
"def_project": "*"
"def_project": "*",
"max_nodes": 2147483647,
"max_cores": 2147483647
}
]
}
Expand Down Expand Up @@ -264,7 +272,9 @@ test_expect_success 'create another user with the same limits in multiple banks'
"queues": "",
"active": 1,
"projects": "*",
"def_project": "*"
"def_project": "*",
"max_nodes": 2147483647,
"max_cores": 2147483647
},
{
"userid": 5012,
Expand All @@ -276,7 +286,9 @@ test_expect_success 'create another user with the same limits in multiple banks'
"queues": "",
"active": 1,
"projects": "*",
"def_project": "*"
"def_project": "*",
"max_nodes": 2147483647,
"max_cores": 2147483647
}
]
}
Expand Down
8 changes: 6 additions & 2 deletions t/t1012-mf-priority-load.t
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,9 @@ test_expect_success 'create fake_payload.py' '
"queues": "",
"active": 1,
"projects": "*",
"def_project": "*"
"def_project": "*",
"max_nodes": 2147483647,
"max_cores": 2147483647
},
{
"userid": userid,
Expand All @@ -54,7 +56,9 @@ test_expect_success 'create fake_payload.py' '
"queues": "",
"active": 1,
"projects": "*",
"def_project": "*"
"def_project": "*",
"max_nodes": 2147483647,
"max_cores": 2147483647
}
]
}
Expand Down

0 comments on commit 57c782e

Please sign in to comment.