(rule_runner: RuleRunner)
| 241 | |
| 242 | |
| 243 | def test_setup_kwargs_plugin(rule_runner: RuleRunner) -> None: |
| 244 | |
| 245 | rule_runner.write_files( |
| 246 | { |
| 247 | "runners/foobar_runner/BUILD": dedent( |
| 248 | """\ |
| 249 | python_distribution( |
| 250 | provides=python_artifact( |
| 251 | name="stackstorm-runner-foobar", |
| 252 | description="Foobar runner for ST2", |
| 253 | version_file="foobar_runner/__init__.py", |
| 254 | classifiers=["Qwerty :: Asdf :: Zxcv"], |
| 255 | ), |
| 256 | dependencies=[ |
| 257 | "./foobar_runner", |
| 258 | ], |
| 259 | entry_points={ |
| 260 | "st2common.runners.runner": { |
| 261 | "foobar": "foobar_runner.foobar_runner", |
| 262 | }, |
| 263 | }, |
| 264 | ) |
| 265 | """ |
| 266 | ), |
| 267 | "runners/foobar_runner/foobar_runner/__init__.py": '__version__ = "0.0test0"', |
| 268 | }, |
| 269 | ) |
| 270 | |
| 271 | address = Address("runners/foobar_runner") |
| 272 | assert gen_setup_kwargs(address, rule_runner) == SetupKwargs( |
| 273 | FrozenDict( |
| 274 | { |
| 275 | "name": "stackstorm-runner-foobar", |
| 276 | "description": "Foobar runner for ST2", |
| 277 | "author": "StackStorm", |
| 278 | "author_email": "info@stackstorm.com", |
| 279 | "url": "https://stackstorm.com", |
| 280 | "license": "Apache License, Version 2.0", |
| 281 | "project_urls": FrozenDict(PROJECT_URLS), |
| 282 | "version": "0.0test0", |
| 283 | "classifiers": ( |
| 284 | *META_CLASSIFIERS, |
| 285 | LINUX_CLASSIFIER, |
| 286 | "Programming Language :: Python", |
| 287 | "Programming Language :: Python :: 3", |
| 288 | "Programming Language :: Python :: 3.6", |
| 289 | "Programming Language :: Python :: 3.8", |
| 290 | "Qwerty :: Asdf :: Zxcv", |
| 291 | ), |
| 292 | } |
| 293 | ), |
| 294 | address=address, |
| 295 | ) |
| 296 | |
| 297 | |
| 298 | def test_setup_kwargs_plugin_with_readme(rule_runner: RuleRunner) -> None: |
nothing calls this directly
no test coverage detected