Skip to content

Commit 4b84f9b

Browse files
authored
Merge pull request #197 from laminas/renovate/lock-file-maintenance
chore(deps): lock file maintenance
2 parents 2b73a72 + 394176c commit 4b84f9b

File tree

12 files changed

+990
-671
lines changed

12 files changed

+990
-671
lines changed

.laminas-ci.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
{
22
"extensions": [
33
"bcmath"
4+
],
5+
"ini": [
6+
"memory_limit=-1"
47
]
58
}

bin/console.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,6 @@ static function (int $errorCode, string $message = '', string $file = '', int $l
107107
$logger
108108
);
109109

110-
/** @psalm-suppress DeprecatedClass */
111110
$application = new Application(Versions::rootPackageName(), Versions::getVersion('laminas/automatic-releases'));
112111

113112
$application->addCommands([

composer.lock

Lines changed: 923 additions & 656 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

psalm.xml.dist

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
<?xml version="1.0"?>
22
<psalm
3-
totallyTyped="true"
3+
errorLevel="1"
44
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
55
xmlns="https://getpsalm.org/schema/config"
66
xsi:schemaLocation="https://getpsalm.org/schema/config vendor/vimeo/psalm/config.xsd"
7+
findUnusedPsalmSuppress="true"
78
>
89
<projectFiles>
910
<directory name="bin"/>

renovate.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,11 @@
22
"$schema": "https://docs.renovatebot.com/renovate-schema.json",
33
"extends": [
44
"local>laminas/.github:renovate-config"
5+
],
6+
"packageRules": [
7+
{
8+
"matchDepTypes": ["require"],
9+
"rangeStrategy": "bump"
10+
}
511
]
612
}

src/Changelog/ChangelogReleaseNotes.php

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,7 @@ public function __construct(
5555
$changelogEntry = clone $changelogEntry;
5656
}
5757

58-
$this->contents = $contents;
59-
60-
/** @psalm-suppress ImpurePropertyAssignment */
58+
$this->contents = $contents;
6159
$this->changelogEntry = $changelogEntry;
6260
}
6361

@@ -69,6 +67,7 @@ public function contents(): string
6967
return $this->contents;
7068
}
7169

70+
/** @throws RuntimeException if release notes already exist in both merged objects. */
7271
public function merge(self $next): self
7372
{
7473
if ($this->changelogEntry && $next->changelogEntry) {
@@ -83,9 +82,8 @@ public function merge(self $next): self
8382
$changelogEntry = clone $changelogEntry;
8483
}
8584

86-
$merged = clone $this;
87-
$merged->contents .= self::CONCATENATION_STRING . $next->contents;
88-
/** @psalm-suppress ImpurePropertyAssignment */
85+
$merged = clone $this;
86+
$merged->contents .= self::CONCATENATION_STRING . $next->contents;
8987
$merged->changelogEntry = $changelogEntry;
9088

9189
return $merged;

src/Github/Api/GraphQL/Query/GetMilestoneChangelog/Response/IssueOrPullRequest.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,6 @@ final class IssueOrPullRequest
2727
/**
2828
* @psalm-param non-empty-string $title
2929
* @psalm-param list<Label> $labels
30-
*
31-
* @psalm-suppress ImpurePropertyAssignment {@see UriInterface} is pure
3230
*/
3331
private function __construct(
3432
int $number,

src/Github/Api/GraphQL/Query/GetMilestoneChangelog/Response/Label.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@ final class Label
2222
/**
2323
* @psalm-param non-empty-string $colour
2424
* @psalm-param non-empty-string $name
25-
*
26-
* @psalm-suppress ImpurePropertyAssignment {@see UriInterface} is pure
2725
*/
2826
private function __construct(
2927
string $colour,

src/Github/Api/GraphQL/Query/GetMilestoneChangelog/Response/Milestone.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,6 @@ final class Milestone
3030
* @param array<int, IssueOrPullRequest> $entries
3131
* @psalm-param non-empty-string $title
3232
* @psalm-param list<IssueOrPullRequest> $entries
33-
*
34-
* @psalm-suppress ImpurePropertyAssignment {@see UriInterface} is pure
3533
*/
3634
private function __construct(
3735
int $number,

test/unit/Application/SwitchDefaultBranchToNextMinorTest.php

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -233,4 +233,37 @@ public function testWillNotSwitchDefaultBranchIfNoBranchesExist(): void
233233
$output->fetch()
234234
);
235235
}
236+
237+
public function testWillRefuseToOperateWhenNotGivenAGitWorkingDirectory(): void
238+
{
239+
$workspace = Filesystem\create_temporary_file(Env\temp_dir(), 'workspace');
240+
241+
Filesystem\delete_file($workspace);
242+
Filesystem\create_directory($workspace);
243+
244+
$this->variables->method('githubWorkspacePath')
245+
->willReturn($workspace);
246+
247+
$this->loadEvent->method('__invoke')
248+
->willReturn($this->event);
249+
250+
$this->fetch->expects(self::never())
251+
->method('__invoke');
252+
253+
$this->getMergeTargets->expects(self::never())
254+
->method('__invoke');
255+
256+
$this->push->expects(self::never())
257+
->method('__invoke');
258+
259+
$this->bumpChangelogVersion->expects(self::never())
260+
->method('__invoke');
261+
262+
$this->setDefaultBranch->expects(self::never())
263+
->method('__invoke');
264+
265+
$this->expectExceptionMessage('Workspace is not a GIT repository.');
266+
267+
$this->command->run(new ArrayInput([]), new NullOutput());
268+
}
236269
}

0 commit comments

Comments
 (0)