This repository was archived by the owner on Mar 13, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +9
-9
lines changed
Expand file tree Collapse file tree 2 files changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -32,15 +32,17 @@ dev = [
3232 " sphinx-autobuild" ,
3333 " sphinx-copybutton" ,
3434 " sphinx-design" ,
35+ " toml" ,
3536 " tox-direct" ,
3637 " types-mock" ,
38+ " types-toml" ,
3739]
3840
3941[project .scripts ]
4042python3-pip-skeleton = " python3_pip_skeleton.__main__:main"
4143
4244[project .urls ]
43- GitHub = " https://github.com/DiamondLightSource/python3-pip-skeleton"
45+ GitHub = " https://github.com/DiamondLightSource/python3-pip-skeleton-cli "
4446
4547[[project .authors ]] # Further authors may be added by duplicating this section
4648@@ -96,8 +98,8 @@ skipsdist=True
9698# Don't create a virtualenv for the command, requires tox-direct plugin
9799direct = True
98100passenv = *
99- allowlist_externals =
100- pytest
101+ allowlist_externals =
102+ pytest
101103 pre-commit
102104 mypy
103105 sphinx-build
Original file line number Diff line number Diff line change 11import subprocess
22import sys
3- from configparser import ConfigParser
43from os import makedirs
54from pathlib import Path
65
76import pytest
7+ import toml
88
99from python3_pip_skeleton import __main__ , __version__
1010
@@ -40,10 +40,9 @@ def test_new_module(tmp_path: Path):
4040 "Developer instructions in docs/developer/tutorials/dev-install.rst"
4141 )
4242
43- conf = ConfigParser ()
44- conf .read (module / "setup.cfg" )
45- assert conf ["metadata" ]["author" ] == "Firstname Lastname"
46- assert conf [
"metadata" ][
"author_email" ]
== "[email protected] " 43+ conf = toml .load (module / "pyproject.toml" )
44+ assert conf [
"project" ][
"authors" ][
0 ][
"email" ]
== "[email protected] " 45+ assert conf ["project" ]["authors" ][0 ]["name" ] == "Firstname Lastname"
4746 api_rst = module / "docs" / "user" / "reference" / "api.rst"
4847 assert (
4948 "Version number as calculated by https://github.com/pypa/setuptools_scm"
@@ -68,7 +67,6 @@ def test_new_module(tmp_path: Path):
6867 out = ctx .value .args [0 ]
6968 print (out )
7069 assert "4 failed, 1 passed" in out
71- assert "Please change description in ./setup.cfg" in out
7270 assert "Please change ./README.rst" in out
7371
7472
You can’t perform that action at this time.
0 commit comments