-
-
Notifications
You must be signed in to change notification settings - Fork 122
Fixed extracting of first sentence from the text containing backticks #228
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
samdark
merged 64 commits into
yiisoft:master
from
arogachev:128-first-sentence-backticks
Dec 1, 2021
Merged
Changes from all commits
Commits
Show all changes
64 commits
Select commit
Hold shift + click to select a range
7aa586d
Draft for 3.0
0f5df6c
Merge remote-tracking branch 'origin/3.0' into 3.0
arogachev b8e27f6
Simplify dependencies in composer.json
arogachev ac33ed2
Minimal working version, various fixes
arogachev 072e760
Remove older PHP versions for tests, add PHP 8
arogachev 1ac13d8
Allow PHP 8 as a dependency in composer.json
arogachev 79f933e
Leave hard coded value (isReturnByReference in FunctionDoc)
arogachev b1095fc
Remove unnecessary elseif block
arogachev c70b044
Move construct method to the top, remove commented out code
arogachev 22ab8c5
Make use of StringHelper::mb_ucfirst()
arogachev 2f798bf
Actualize stubs for setting type and types based on getType()
arogachev 186944f
Use fork, restore endLine and isReturnByReference logic
arogachev aaf5dbd
Handle getNode()->default, do not remove deprecated methods' bodies
arogachev d12e8ce
Removed author for consistency
arogachev 6036566
Cleanup
arogachev 7f1178a
Handle type / types in TypeDoc, get rid of addProjectFile
arogachev b3b44fc
Fix undefined variable $type
arogachev e4f989c
Cleanup tests
arogachev ab6b134
Fix first 5 errors after testing on Yii 2 docs
arogachev 01f5450
Make setUp compatible with parent (PHPUnit)
arogachev 63f5426
Fix "Undefined array key 0" error
arogachev 1207b7a
Fix "Call to undefined method Generic::getContent()" in Context
arogachev fcafd6a
Fix "Class Collection not found" error
arogachev f246153
Fix regression with parentheses with MethodDoc
arogachev 73f12e8
Fix property-read / property-write parsing issues
arogachev 3b700bd
Fix event description (was merged with class name and not capitalized)
arogachev 7b3e0d3
Fix issue when "seeAlso" partial template was not rendered
arogachev b381335
Revert str_contains -> strpos
arogachev 598c559
Handle null in aggregated type during split types
arogachev 1b432ff
Fix broken links
arogachev bfbe60e
Fix regression ("mixed" in params in method signature)
arogachev b901254
This kind of refactoring can be done later (better diffs)
arogachev b710ee2
Fix pretty print of default value in property
arogachev a026269
Fix higlighting of backslashes (temporary solution)
arogachev 1cf8015
Use namespace aliases for event names
arogachev 1d2432d
Handle regression \u -> \\u in class constants' values
arogachev 54987b9
Revert hacky attempt of fixing highlighting of backslashes
arogachev c036235
Fix name and type hint for params in method when it's declared via tag
arogachev 43c814b
Fix as many warnings as possible, check docstrings
arogachev b8d5890
Update CHANGELOG.md
arogachev 6895aa4
Update renderers/BaseRenderer.php
arogachev c3eadfe
Simplify string concatenation even more
arogachev 8dd3238
Issue #133 is fixed too [skip ci]
arogachev bb1d465
Issue #155 is fixed too [skip ci]
arogachev 87b8d63
Issue #162 is fixed too [skip ci]
arogachev 21f8055
Issue #179 is fixed too [skip ci]
arogachev bcc44fa
Issue #199 is fixed too [skip ci]
arogachev 7e98c64
Fix issue #143 (do not include internal methods and properties) [skip...
arogachev 255733f
Add issue #180 in CHANGELOG.md[skip ci]
arogachev f9bef8f
Add issue #148 to CHANGELOG.md [skip ci]
arogachev 5b2f0b7
Fixed issue #197 [skip ci]
arogachev 7ceaa5a
Add prefix and suffix when fixing Markdown links
arogachev 969362b
Merge branch 'master' into 3.0
arogachev bb94d19
Do not add guide prefix to non-Markdown links
arogachev 5b068ef
Extract changes for issue #180 to a separate branch
arogachev d97b25c
Extract changes for issue #197 to a separate branch
arogachev 0ec0800
Remove whitespace at the end of line [skip ci]
arogachev e1baa3d
Fixed extracting of first sentence from the text containing backticks
arogachev 5bfb0f3
Merge branch 'master' into 128-first-sentence-backticks
samdark 0d734a0
Merge branch 'master' into 128-first-sentence-backticks
arogachev 9fe7274
Merge remote-tracking branch 'origin/128-first-sentence-backticks' in...
arogachev e04ed05
Sync CHANGELOG.md with master
arogachev 0b23716
Sync PrettyPrinter.php with master
arogachev 3bde22d
Merge branch 'master' into 128-first-sentence-backticks
samdark File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 25 additions & 0 deletions
tests/models/BaseDocTest.php
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,25 @@ | ||
| <?php | ||
| /** | ||
| * @link http://www.yiiframework.com/ | ||
| * @copyright Copyright (c) 2008 Yii Software LLC | ||
| * @license http://www.yiiframework.com/license/ | ||
| */ | ||
|
|
||
| namespace yiiunit\apidoc\models; | ||
|
|
||
| use PHPUnit\Framework\TestCase; | ||
| use yii\apidoc\models\BaseDoc; | ||
|
|
||
| class BaseDocTest extends TestCase | ||
| { | ||
| /** | ||
| * @link https://github.com/yiisoft/yii2-apidoc/issues/128 | ||
| */ | ||
| public function testExtractFirstSentenceWithBackticks() | ||
| { | ||
| $initialText = 'the host info (e.g. `http://www.example.com`) that is used by [[createAbsoluteUrl()]] to ' . | ||
| 'prepend to created URLs.'; | ||
| $firstSentence = BaseDoc::extractFirstSentence($initialText); | ||
| $this->assertEquals($initialText, $firstSentence);; | ||
| } | ||
| } |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.