Skip to content
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

Fix supperflous fields error bunq/sdk_php#118 #125

Merged
merged 12 commits into from
Apr 6, 2018

Conversation

OGKevin
Copy link
Contributor

@OGKevin OGKevin commented Apr 5, 2018

This PR closes/fixes the following issues:

must be merged after #124

@OGKevin OGKevin added this to the 0.13.5 milestone Apr 5, 2018
@OGKevin OGKevin self-assigned this Apr 5, 2018
@OGKevin OGKevin added this to To do in 1.0.0 - SDK via automation Apr 5, 2018
@OGKevin OGKevin moved this from To do to open PR in 1.0.0 - SDK Apr 5, 2018
@OGKevin OGKevin changed the title Fix supperfouls fields error bunq/sdk php#118 Fix supperfouls fields error bunq/sdk_php#118 Apr 5, 2018
Copy link
Contributor Author

@OGKevin OGKevin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove the author headers .

use bunq\test\BunqSdkTestBase;

/**
* @author Kevin Hellemun <khellemun@bunq.com>
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This header can be removed.

use bunq\test\BunqSdkTestBase;

/**
* @author Kevin Hellemun <khellemun@bunq.com>
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

header can be removed.

@OGKevin OGKevin requested a review from sandervdo April 6, 2018 07:52
Copy link
Contributor

@sandervdo sandervdo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

const FORMAT_STRING_EMPTY = '';
const SUFFIX_REQUEST_FIELD = '_field_for_request';


Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove.

use bunq\Model\Generated\Object\Pointer;
use bunq\test\BunqSdkTestBase;

/**
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is so ugly. Why don't we leave it out when we don't adhere strictly to internal codestyle guidelines anyway?

* Test constants
*/
const PAYMENT_CURRENCY = 'EUR';
const PAYMENT_DESCRIPTION = "php sdk Batch test";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Single quotes rather than double qoutes.

*/
public function testSendBatchPayment()
{
$response = PaymentBatch::create(
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fits on one line

{
$allPayment = [];

while (count($allPayment) < 10) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Magic value

@@ -45,4 +35,14 @@ public static function tearDownAfterClass()
BunqContext::getApiContext()->resetSession();
BunqContext::getApiContext()->save(self::FILE_PATH_CONTEXT_CONFIG);
}

/**
* Delete's the current session.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deletes

/**
* Delete's the current session.
*
* This test has no assertion as of its testing to see if the code runs without errors.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

as it is testing whether the code runs without errors.

Same typo as in other PR. Generated/copied error?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nah, back in the day when we were using the old PhpUnit you could leave tests without assertions hence the message in the test header. Since #96 it will say risky tests if no assertions where added. But I seem to forgot to remove these comments 🤦‍♂️

sandervdo
sandervdo previously approved these changes Apr 6, 2018
@OGKevin OGKevin merged commit f13be0f into develop Apr 6, 2018
1.0.0 - SDK automation moved this from open PR to merged Apr 6, 2018
@OGKevin OGKevin deleted the fix_supperfouls_fields_error_bunq/sdk_php#118 branch April 6, 2018 18:42
@OGKevin
Copy link
Contributor Author

OGKevin commented Apr 6, 2018

@andrederoos

@OGKevin OGKevin changed the title Fix supperfouls fields error bunq/sdk_php#118 Fix supperflous fields error bunq/sdk_php#118 Apr 9, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
1.0.0 - SDK
  
merged
Development

Successfully merging this pull request may close these issues.

Can not construct a BunqMeTabEntry for use with BunqMeTab::create()
2 participants