Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: symfony/smsc-notifier
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v6.3.11
Choose a base ref
...
head repository: symfony/smsc-notifier
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 7.2
Choose a head ref

Commits on May 23, 2023

  1. [6.4] Allow 7.0 deps

    nicolas-grekas committed May 23, 2023
    Copy the full SHA
    f20b024 View commit details
  2. Copy the full SHA
    2474671 View commit details

Commits on Dec 28, 2023

  1. Merge branch '6.3' into 6.4

    * 6.3:
      [VarDumper] Fix CSS alignment in HtmlDumper
      allow environment variables starting with an underscore
      Update a test
      [Mailer][Postmark] Add missing changelog for webhook support
      Remove #StandWithUkraine
      [Notifier][Smsc] Require login and password
    fabpot committed Dec 28, 2023
    Copy the full SHA
    b017e8b View commit details
  2. Merge branch '6.4' into 7.0

    * 6.4:
      [VarDumper] Fix CSS alignment in HtmlDumper
      allow environment variables starting with an underscore
      Update a test
      [PsrHttpMessageBridge] Fix links in composer.json
      [Mailer][Postmark] Add missing changelog for webhook support
      Remove #StandWithUkraine
      [Notifier][Smsc] Require login and password
    fabpot committed Dec 28, 2023
    Copy the full SHA
    7225d4e View commit details

Commits on Jan 2, 2024

  1. [Notifier] [Bridges] Use CPP

    OskarStark authored and nicolas-grekas committed Jan 2, 2024
    Copy the full SHA
    4ff3c25 View commit details

Commits on Jan 23, 2024

  1. Copy the full SHA
    77cf825 View commit details
  2. Merge branch '5.4' into 6.3

    * 5.4:
      Fix implicitly-required parameters
      List CS fix in .git-blame-ignore-revs
      Apply php-cs-fixer fix --rules nullable_type_declaration_for_default_null_value
      [Messenger][AmazonSqs] Allow async-aws/sqs version 2
    nicolas-grekas committed Jan 23, 2024
    Copy the full SHA
    0d5ec8d View commit details
  3. Merge branch '6.3' into 6.4

    * 6.3:
      minor #53524 [Messenger] [AmazonSqs] Allow `async-aws/sqs` version 2 (smoench)
      Fix bad merge
      List CS fix in .git-blame-ignore-revs
      Fix implicitly-required parameters
      List CS fix in .git-blame-ignore-revs
      Apply php-cs-fixer fix --rules nullable_type_declaration_for_default_null_value
    nicolas-grekas committed Jan 23, 2024
    Copy the full SHA
    abdb690 View commit details
  4. Merge branch '6.4' into 7.0

    * 6.4:
      Fix implicitly-required parameters
      minor #53524 [Messenger] [AmazonSqs] Allow `async-aws/sqs` version 2 (smoench)
      Fix bad merge
      List CS fix in .git-blame-ignore-revs
      Fix implicitly-required parameters
      List CS fix in .git-blame-ignore-revs
      Apply php-cs-fixer fix --rules nullable_type_declaration_for_default_null_value
      [Messenger][AmazonSqs] Allow async-aws/sqs version 2
    nicolas-grekas committed Jan 23, 2024
    Copy the full SHA
    484c661 View commit details
  5. Merge branch '7.0' into 7.1

    * 7.0:
      List CS fix in .git-blame-ignore-revs
      Fix implicitly-required parameters
      minor #53524 [Messenger] [AmazonSqs] Allow `async-aws/sqs` version 2 (smoench)
      Fix bad merge
      List CS fix in .git-blame-ignore-revs
      Fix implicitly-required parameters
      List CS fix in .git-blame-ignore-revs
      Apply php-cs-fixer fix --rules nullable_type_declaration_for_default_null_value
      [Messenger][AmazonSqs] Allow async-aws/sqs version 2
    nicolas-grekas committed Jan 23, 2024
    Copy the full SHA
    df57c58 View commit details

Commits on Mar 20, 2024

  1. chore: CS fixes

    keradus authored and nicolas-grekas committed Mar 20, 2024
    Copy the full SHA
    3560c4d View commit details

Commits on Apr 18, 2024

  1. Copy the full SHA
    1b2f894 View commit details
  2. Merge branch '5.4' into 6.4

    * 5.4:
      Auto-close PRs on subtree-splits
      review German translation
    nicolas-grekas committed Apr 18, 2024
    Copy the full SHA
    9194ba9 View commit details
  3. Merge branch '6.4' into 7.0

    * 6.4:
      Auto-close PRs on subtree-splits
      review German translation
    nicolas-grekas committed Apr 18, 2024
    Copy the full SHA
    fb767c6 View commit details
  4. Merge branch '7.0' into 7.1

    * 7.0:
      Auto-close PRs on subtree-splits
      review German translation
    nicolas-grekas committed Apr 18, 2024
    Copy the full SHA
    8119019 View commit details

Commits on May 31, 2024

  1. Revert "minor #54653 Auto-close PRs on subtree-splits (nicolas-grekas)"

    This reverts commit 2c9352dd91ebaf37b8a3e3c26fd8e1306df2fb73, reversing
    changes made to 18c3e87f1512be2cc50e90235b144b13bc347258.
    fabpot committed May 31, 2024
    Copy the full SHA
    6c3935e View commit details
  2. Merge branch '5.4' into 6.4

    * 5.4:
      Revert "minor #54653 Auto-close PRs on subtree-splits (nicolas-grekas)"
    fabpot committed May 31, 2024
    Copy the full SHA
    3f799b7 View commit details
  3. Merge branch '6.4' into 7.0

    * 6.4:
      Remove subtree split checks
      Revert "minor #54653 Auto-close PRs on subtree-splits (nicolas-grekas)"
    fabpot committed May 31, 2024
    Copy the full SHA
    3edf631 View commit details
  4. Merge branch '7.0' into 7.1

    * 7.0:
      Remove subtree split checks
      Revert "minor #54653 Auto-close PRs on subtree-splits (nicolas-grekas)"
    fabpot committed May 31, 2024
    Copy the full SHA
    683fd5e View commit details

Commits on Jun 20, 2024

  1. Prefix all sprintf() calls

    derrabus committed Jun 20, 2024
    Copy the full SHA
    072823d View commit details

Commits on Jul 6, 2024

  1. Update .gitattributes

    fabpot committed Jul 6, 2024
    Copy the full SHA
    29eaaf9 View commit details

Commits on Sep 23, 2024

  1. Copy the full SHA
    b014c3d View commit details

Commits on Sep 25, 2024

  1. Copy the full SHA
    4b03c5c View commit details
  2. Merge branch '5.4' into 6.4

    * 5.4:
      Add PR template and auto-close PR on subtree split repositories
    nicolas-grekas committed Sep 25, 2024
    Copy the full SHA
    999d597 View commit details
  3. Merge branch '6.4' into 7.1

    * 6.4:
      Add PR template and auto-close PR on subtree split repositories
    nicolas-grekas committed Sep 25, 2024
    Copy the full SHA
    ff84a73 View commit details
  4. Merge branch '7.1' into 7.2

    * 7.1:
      Add PR template and auto-close PR on subtree split repositories
    nicolas-grekas committed Sep 25, 2024
    Copy the full SHA
    8ed87de View commit details

Commits on Sep 27, 2024

  1. feature #58335 [Notifier] deprecate the TransportFactoryTestCase (xab…

    …buh)
    
    This PR was merged into the 7.2 branch.
    
    Discussion
    ----------
    
    [Notifier] deprecate the TransportFactoryTestCase
    
    | Q             | A
    | ------------- | ---
    | Branch?       | 7.2
    | Bug fix?      | no
    | New feature?  | no
    | Deprecations? | yes
    | Issues        | Fix #54100
    | License       | MIT
    
    Commits
    -------
    
    c8b0fcc77b deprecate the TransportFactoryTestCase
    fabpot committed Sep 27, 2024
    Copy the full SHA
    56753d0 View commit details
Showing with 48 additions and 21 deletions.
  1. +1 −2 .gitattributes
  2. +8 −0 .github/PULL_REQUEST_TEMPLATE.md
  3. +20 −0 .github/workflows/close-pull-request.yml
  4. +10 −13 SmscTransport.php
  5. +5 −2 Tests/SmscTransportFactoryTest.php
  6. +1 −1 Tests/SmscTransportTest.php
  7. +3 −3 composer.json
3 changes: 1 addition & 2 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
/Tests export-ignore
/phpunit.xml.dist export-ignore
/.gitattributes export-ignore
/.gitignore export-ignore
/.git* export-ignore
8 changes: 8 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
Please do not submit any Pull Requests here. They will be closed.
---

Please submit your PR here instead:
https://github.com/symfony/symfony

This repository is what we call a "subtree split": a read-only subset of that main repository.
We're looking forward to your PR there!
20 changes: 20 additions & 0 deletions .github/workflows/close-pull-request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Close Pull Request

on:
pull_request_target:
types: [opened]

jobs:
run:
runs-on: ubuntu-latest
steps:
- uses: superbrothers/close-pull-request@v3
with:
comment: |
Thanks for your Pull Request! We love contributions.
However, you should instead open your PR on the main repository:
https://github.com/symfony/symfony
This repository is what we call a "subtree split": a read-only subset of that main repository.
We're looking forward to your PR there!
23 changes: 10 additions & 13 deletions SmscTransport.php
Original file line number Diff line number Diff line change
@@ -30,22 +30,19 @@ final class SmscTransport extends AbstractTransport
{
protected const HOST = 'smsc.ru';

private ?string $login;
private ?string $password;
private string $from;

public function __construct(string $login, #[\SensitiveParameter] string $password, string $from, HttpClientInterface $client = null, EventDispatcherInterface $dispatcher = null)
{
$this->login = $login;
$this->password = $password;
$this->from = $from;

public function __construct(
private string $login,
#[\SensitiveParameter] private string $password,
private string $from,
?HttpClientInterface $client = null,
?EventDispatcherInterface $dispatcher = null,
) {
parent::__construct($client, $dispatcher);
}

public function __toString(): string
{
return sprintf('smsc://%s?from=%s', $this->getEndpoint(), $this->from);
return \sprintf('smsc://%s?from=%s', $this->getEndpoint(), $this->from);
}

public function supports(MessageInterface $message): bool
@@ -70,7 +67,7 @@ protected function doSend(MessageInterface $message): SentMessage
'time' => '0-24',
];

$endpoint = sprintf('https://%s/sys/send.php', $this->getEndpoint());
$endpoint = \sprintf('https://%s/sys/send.php', $this->getEndpoint());
$response = $this->client->request('POST', $endpoint, ['body' => $body]);

try {
@@ -84,7 +81,7 @@ protected function doSend(MessageInterface $message): SentMessage
}

if (\array_key_exists('error', $result)) {
throw new TransportException(sprintf('Unable to send the SMS: code = %d, message = "%s".', $result['error_code'], $result['error']), $response);
throw new TransportException(\sprintf('Unable to send the SMS: code = %d, message = "%s".', $result['error_code'], $result['error']), $response);
}

$sentMessage = new SentMessage($message, (string) $this);
7 changes: 5 additions & 2 deletions Tests/SmscTransportFactoryTest.php
Original file line number Diff line number Diff line change
@@ -12,10 +12,13 @@
namespace Symfony\Component\Notifier\Bridge\Smsc\Tests;

use Symfony\Component\Notifier\Bridge\Smsc\SmscTransportFactory;
use Symfony\Component\Notifier\Test\TransportFactoryTestCase;
use Symfony\Component\Notifier\Test\AbstractTransportFactoryTestCase;
use Symfony\Component\Notifier\Test\MissingRequiredOptionTestTrait;

final class SmscTransportFactoryTest extends TransportFactoryTestCase
final class SmscTransportFactoryTest extends AbstractTransportFactoryTestCase
{
use MissingRequiredOptionTestTrait;

public function createFactory(): SmscTransportFactory
{
return new SmscTransportFactory();
2 changes: 1 addition & 1 deletion Tests/SmscTransportTest.php
Original file line number Diff line number Diff line change
@@ -21,7 +21,7 @@

final class SmscTransportTest extends TransportTestCase
{
public static function createTransport(HttpClientInterface $client = null): SmscTransport
public static function createTransport(?HttpClientInterface $client = null): SmscTransport
{
return new SmscTransport('login', 'password', 'MyApp', $client ?? new MockHttpClient());
}
6 changes: 3 additions & 3 deletions composer.json
Original file line number Diff line number Diff line change
@@ -16,9 +16,9 @@
}
],
"require": {
"php": ">=8.1",
"symfony/http-client": "^5.4|^6.0",
"symfony/notifier": "^6.2.7"
"php": ">=8.2",
"symfony/http-client": "^6.4|^7.0",
"symfony/notifier": "^7.2"
},
"autoload": {
"psr-4": { "Symfony\\Component\\Notifier\\Bridge\\Smsc\\": "" },