mirror of
https://github.com/jrnl-org/jrnl.git
synced 2025-07-11 17:46:12 +02:00
Merge branch 'develop' into markdown-newline-end
This commit is contained in:
commit
9c849f75f7
8 changed files with 37 additions and 8 deletions
|
@ -129,7 +129,7 @@ Feature: Exporting a Journal
|
|||
"""
|
||||
title: I have an @idea:
|
||||
date: 2013-04-09 15:39
|
||||
stared: False
|
||||
starred: False
|
||||
tags: idea, journal
|
||||
|
||||
(1) write a command line @journal software
|
||||
|
|
|
@ -159,3 +159,10 @@ Feature: Zapped bugs should stay dead.
|
|||
tags:
|
||||
|
||||
"""
|
||||
|
||||
@deployment_tests
|
||||
Scenario: Version numbers should stay in sync
|
||||
Given we use the config "basic.yaml"
|
||||
When we run "jrnl --version"
|
||||
Then we should get no error
|
||||
Then the output should contain pyproject.toml version
|
||||
|
|
|
@ -19,6 +19,8 @@ import keyring
|
|||
import tzlocal
|
||||
import shlex
|
||||
import sys
|
||||
from pathlib import Path
|
||||
import toml
|
||||
|
||||
consts = pdt.Constants(usePyICU=False)
|
||||
consts.DOWParseStyle = -1 # Prefers past weekdays
|
||||
|
@ -207,6 +209,15 @@ def check_output_time_inline(context, text):
|
|||
assert output_date in out, output_date
|
||||
|
||||
|
||||
@then("the output should contain pyproject.toml version")
|
||||
def check_output_version_inline(context):
|
||||
out = context.stdout_capture.getvalue()
|
||||
pyproject = (Path(__file__) / ".." / ".." / ".." / "pyproject.toml").resolve()
|
||||
pyproject_contents = toml.load(pyproject)
|
||||
pyproject_version = pyproject_contents["tool"]["poetry"]["version"]
|
||||
assert pyproject_version in out, pyproject_version
|
||||
|
||||
|
||||
@then("the output should contain")
|
||||
@then('the output should contain "{text}"')
|
||||
@then('the output should contain "{text}" or "{text2}"')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue