@@ -59,54 +59,54 @@ final class OAuth2SummitOrdersApiTest extends ProtectedApiTest
5959
6060 use InsertOrdersTestData;
6161
62- // protected function setUp():void
63- // {
64- // parent::setUp();
65- // self::$test_secret_key = env('TEST_STRIPE_SECRET_KEY');
66- // self::$test_public_key = env('TEST_STRIPE_PUBLISHABLE_KEY');
67- // self::$live_secret_key = env('LIVE_STRIPE_SECRET_KEY');
68- // self::$live_public_key = env('LIVE_STRIPE_PUBLISHABLE_KEY');
69- //
70- // self::insertSummitTestData();
71- // self::InsertOrdersTestData();
72- // // build payment profile and attach to summit
73- // self::$profile = PaymentGatewayProfileFactory::build(IPaymentConstants::ProviderStripe, [
74- // 'application_type' => IPaymentConstants::ApplicationTypeRegistration,
75- // 'is_test_mode' => true,
76- // 'test_publishable_key' => self::$test_public_key,
77- // 'test_secret_key' => self::$test_secret_key,
78- // 'is_active' => false,
79- // ]);
80- //
81- // // build default badge type
82- //
83- // $defaultBadge = SummitBadgeTypeFactory::build([
84- // 'name' => 'DEFAULT',
85- // 'is_default' => true,
86- // ]);
87- //
88- // // build ticket type
89- //
90- // self::$ticketType = SummitTicketTypeFactory::build(self::$summit, [
91- // 'name' => 'TICKET_1',
92- // 'cost' => 100,
93- // 'quantity_2_sell' => 1000,
94- // ]);
95- //
96- // self::$summit->addPaymentProfile(self::$profile);
97- // self::$summit->addBadgeType($defaultBadge);
98- // self::$summit->addTicketType(self::$ticketType);
99- //
100- // self::$em->persist(self::$summit);
101- // self::$em->flush();
102- //
103- // }
104- //
105- // protected function tearDown():void
106- // {
107- // self::clearSummitTestData();
108- // parent::tearDown();
109- // }
62+ protected function setUp ():void
63+ {
64+ parent ::setUp ();
65+ self ::$ test_secret_key = env ('TEST_STRIPE_SECRET_KEY ' );
66+ self ::$ test_public_key = env ('TEST_STRIPE_PUBLISHABLE_KEY ' );
67+ self ::$ live_secret_key = env ('LIVE_STRIPE_SECRET_KEY ' );
68+ self ::$ live_public_key = env ('LIVE_STRIPE_PUBLISHABLE_KEY ' );
69+
70+ self ::insertSummitTestData ();
71+ self ::InsertOrdersTestData ();
72+ // build payment profile and attach to summit
73+ self ::$ profile = PaymentGatewayProfileFactory::build (IPaymentConstants::ProviderStripe, [
74+ 'application_type ' => IPaymentConstants::ApplicationTypeRegistration,
75+ 'is_test_mode ' => true ,
76+ 'test_publishable_key ' => self ::$ test_public_key ,
77+ 'test_secret_key ' => self ::$ test_secret_key ,
78+ 'is_active ' => false ,
79+ ]);
80+
81+ // build default badge type
82+
83+ $ defaultBadge = SummitBadgeTypeFactory::build ([
84+ 'name ' => 'DEFAULT ' ,
85+ 'is_default ' => true ,
86+ ]);
87+
88+ // build ticket type
89+
90+ self ::$ ticketType = SummitTicketTypeFactory::build (self ::$ summit , [
91+ 'name ' => 'TICKET_1 ' ,
92+ 'cost ' => 100 ,
93+ 'quantity_2_sell ' => 1000 ,
94+ ]);
95+
96+ self ::$ summit ->addPaymentProfile (self ::$ profile );
97+ self ::$ summit ->addBadgeType ($ defaultBadge );
98+ self ::$ summit ->addTicketType (self ::$ ticketType );
99+
100+ self ::$ em ->persist (self ::$ summit );
101+ self ::$ em ->flush ();
102+
103+ }
104+
105+ protected function tearDown ():void
106+ {
107+ self ::clearSummitTestData ();
108+ parent ::tearDown ();
109+ }
110110
111111 /**
112112 * @return mixed
0 commit comments