| 1 |  |  | <?php | 
            
                                                                                                            
                            
            
                                    
            
            
                | 2 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 3 |  |  | /* | 
            
                                                                                                            
                            
            
                                    
            
            
                | 4 |  |  |  * This file is part of EC-CUBE | 
            
                                                                                                            
                            
            
                                    
            
            
                | 5 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 6 |  |  |  * Copyright(c) LOCKON CO.,LTD. All Rights Reserved. | 
            
                                                                                                            
                            
            
                                    
            
            
                | 7 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 8 |  |  |  * http://www.lockon.co.jp/ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 9 |  |  |  * | 
            
                                                                                                            
                            
            
                                    
            
            
                | 10 |  |  |  * For the full copyright and license information, please view the LICENSE | 
            
                                                                                                            
                            
            
                                    
            
            
                | 11 |  |  |  * file that was distributed with this source code. | 
            
                                                                                                            
                            
            
                                    
            
            
                | 12 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 13 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 14 |  |  | use Codeception\Util\Fixtures; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 15 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 16 |  |  | /** | 
            
                                                                                                            
                            
            
                                    
            
            
                | 17 |  |  |  * @group front | 
            
                                                                                                            
                            
            
                                    
            
            
                | 18 |  |  |  * @group other | 
            
                                                                                                            
                            
            
                                    
            
            
                | 19 |  |  |  * @group ef6 | 
            
                                                                                                            
                            
            
                                    
            
            
                | 20 |  |  |  */ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 21 |  |  | class EF06OtherCest | 
            
                                                                                                            
                            
            
                                    
            
            
                | 22 |  |  | { | 
            
                                                                                                            
                            
            
                                                                    
                                                                                                        
            
            
                | 23 |  | View Code Duplication |     public function other_ログイン正常(\AcceptanceTester $I) | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 24 |  |  |     { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 25 |  |  |         $I->wantTo('EF0601-UC01-T01 ログイン 正常パターン'); | 
            
                                                                                                            
                                                                
            
                                    
            
            
                | 26 |  |  |         $I->logoutAsMember(); | 
            
                                                                        
                            
            
                                    
            
            
                | 27 |  |  |  | 
            
                                                                        
                            
            
                                    
            
            
                | 28 |  |  |         $createCustomer = Fixtures::get('createCustomer'); | 
            
                                                                        
                            
            
                                    
            
            
                | 29 |  |  |         $customer = $createCustomer(); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 30 |  |  |         $I->loginAsMember($customer->getEmail(), 'password'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 31 |  |  |     } | 
            
                                                                                                            
                            
            
                                    
            
            
                | 32 |  |  |  | 
            
                                                                                                            
                            
            
                                                                    
                                                                                                        
            
            
                | 33 |  | View Code Duplication |     public function other_ログイン異常1(\AcceptanceTester $I) | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 34 |  |  |     { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 35 |  |  |         $I->wantTo('EF0601-UC01-T02 ログイン 異常パターン(仮会員)'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 36 |  |  |         $I->logoutAsMember(); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 37 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 38 |  |  |         $createCustomer = Fixtures::get('createCustomer'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 39 |  |  |         $customer = $createCustomer(null, false); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 40 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 41 |  |  |         $I->amOnPage('/mypage/login'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 42 |  |  |         $I->submitForm('#login_mypage', [ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 43 |  |  |             'login_email' => $customer->getEmail(), | 
            
                                                                                                            
                            
            
                                    
            
            
                | 44 |  |  |             'login_pass' => 'password', | 
            
                                                                                                            
                            
            
                                    
            
            
                | 45 |  |  |         ]); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 46 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 47 |  |  |         $I->see('ログインできませんでした。', 'div.ec-login p.ec-errorMessage'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 48 |  |  |     } | 
            
                                                                                                            
                            
            
                                    
            
            
                | 49 |  |  |  | 
            
                                                                                                            
                            
            
                                                                    
                                                                                                        
            
            
                | 50 |  | View Code Duplication |     public function other_ログイン異常2(\AcceptanceTester $I) | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 51 |  |  |     { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 52 |  |  |         $I->wantTo('EF0601-UC01-T03 ログイン 異常パターン(入力ミス)'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 53 |  |  |         $I->logoutAsMember(); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 54 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 55 |  |  |         $createCustomer = Fixtures::get('createCustomer'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 56 |  |  |         $customer = $createCustomer(null, false); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 57 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 58 |  |  |         $I->amOnPage('/mypage/login'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 59 |  |  |         $I->submitForm('#login_mypage', [ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 60 |  |  |             'login_email' => $customer->getEmail().'.bad', | 
            
                                                                                                            
                            
            
                                    
            
            
                | 61 |  |  |             'login_pass' => 'password', | 
            
                                                                                                            
                            
            
                                    
            
            
                | 62 |  |  |         ]); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 63 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 64 |  |  |         $I->see('ログインできませんでした。', 'div.ec-login p.ec-errorMessage'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 65 |  |  |     } | 
            
                                                                                                            
                            
            
                                    
            
            
                | 66 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 67 |  |  |     public function other_パスワード再発行(\AcceptanceTester $I) | 
            
                                                                                                            
                            
            
                                    
            
            
                | 68 |  |  |     { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 69 |  |  |         $I->wantTo('EF0602-UC01-T01 パスワード再発行'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 70 |  |  |         $I->logoutAsMember(); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 71 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 72 |  |  |         // TOPページ→ログイン(「ログイン情報をお忘れですか?」リンクを押下する)→パスワード再発行 | 
            
                                                                                                            
                            
            
                                    
            
            
                | 73 |  |  |         $I->amOnPage('/mypage/login'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 74 |  |  |         //$I->click('ログイン情報をお忘れですか', '#login_mypage #login_box .btn_area ul li a'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 75 |  |  |         $I->amOnPage('/forgot'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 76 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 77 |  |  |         // TOPページ>ログイン>パスワード再発行 | 
            
                                                                                                            
                            
            
                                    
            
            
                | 78 |  |  |         $I->see('パスワードの再発行', 'div.ec-pageHeader h1'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 79 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 80 |  |  |         // メールアドレスを入力する | 
            
                                                                                                            
                            
            
                                    
            
            
                | 81 |  |  |         // 「次のページへ」ボタンを押下する | 
            
                                                                                                            
                            
            
                                    
            
            
                | 82 |  |  |         $createCustomer = Fixtures::get('createCustomer'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 83 |  |  |         $customer = $createCustomer(); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 84 |  |  |         $I->resetEmails(); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 85 |  |  |         $I->submitForm('#form1', [ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 86 |  |  |             'login_email' => $customer->getEmail(), | 
            
                                                                                                            
                            
            
                                    
            
            
                | 87 |  |  |         ]); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 88 |  |  |         $I->see('パスワードの再発行(メール送信)', 'div.ec-pageHeader h1'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 89 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 90 |  |  |         $I->seeEmailCount(1); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 91 |  |  |         $I->seeInLastEmailSubjectTo($customer->getEmail(), 'パスワード変更のご確認'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 92 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 93 |  |  |         $url = $I->grabFromLastEmailTo($customer->getEmail(), '@/forgot/reset/(.*)@'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 94 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 95 |  |  |         $I->resetEmails(); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 96 |  |  |         $I->amOnPage($url); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 97 |  |  |         $I->see('パスワード再発行(再設定ページ)', 'div.ec-pageHeader h1'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 98 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 99 |  |  |         $password = substr(str_shuffle('1234567890abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ'), 0, 20); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 100 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 101 |  |  |         // メルアド・新パスワード設定 | 
            
                                                                                                            
                            
            
                                    
            
            
                | 102 |  |  |         $I->submitForm('#form1', [ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 103 |  |  |             'login_email' => $customer->getEmail(), | 
            
                                                                                                            
                            
            
                                    
            
            
                | 104 |  |  |             'password[first]' => $password, | 
            
                                                                                                            
                            
            
                                    
            
            
                | 105 |  |  |             'password[second]' => $password, | 
            
                                                                                                            
                            
            
                                    
            
            
                | 106 |  |  |         ]); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 107 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 108 |  |  |         $I->see('ログイン', 'div.ec-pageHeader h1'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 109 |  |  |         $I->loginAsMember($customer->getEmail(), $password); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 110 |  |  |     } | 
            
                                                                                                            
                            
            
                                    
            
            
                | 111 |  |  |  | 
            
                                                                                                            
                            
            
                                                                    
                                                                                                        
            
            
                | 112 |  | View Code Duplication |     public function other_ログアウト(\AcceptanceTester $I) | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 113 |  |  |     { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 114 |  |  |         $I->wantTo('EF0603-UC01-T01 ログアウト'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 115 |  |  |         $I->logoutAsMember(); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 116 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 117 |  |  |         $createCustomer = Fixtures::get('createCustomer'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 118 |  |  |         $customer = $createCustomer(); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 119 |  |  |         $I->loginAsMember($customer->getEmail(), 'password'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 120 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 121 |  |  |         $I->logoutAsMember(); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 122 |  |  |     } | 
            
                                                                                                            
                            
            
                                    
            
            
                | 123 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 124 |  |  |     public function other_当サイトについて(\AcceptanceTester $I) | 
            
                                                                                                            
                            
            
                                    
            
            
                | 125 |  |  |     { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 126 |  |  |         $I->wantTo('EF0604-UC01-T01 当サイトについて'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 127 |  |  |         $I->amOnPage('/'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 128 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 129 |  |  |         $I->scrollTo('.ec-footerNavi .ec-footerNavi__link:nth-child(1) a', 0, 200); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 130 |  |  |         $I->click('.ec-footerNavi .ec-footerNavi__link:nth-child(1) a'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 131 |  |  |         $I->see('当サイトについて', 'div.ec-pageHeader h1'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 132 |  |  |         $baseinfo = Fixtures::get('baseinfo'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 133 |  |  |         $I->see($baseinfo->getShopName(), '#help_about_box__shop_name'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 134 |  |  |     } | 
            
                                                                                                            
                            
            
                                    
            
            
                | 135 |  |  |  | 
            
                                                                                                            
                            
            
                                                                    
                                                                                                        
            
            
                | 136 |  | View Code Duplication |     public function other_プライバシーポリシー(\AcceptanceTester $I) | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 137 |  |  |     { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 138 |  |  |         $I->wantTo('EF0605-UC01-T01 プライバシーポリシー'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 139 |  |  |         $I->amOnPage('/'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 140 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 141 |  |  |         $I->scrollTo('.ec-footerNavi .ec-footerNavi__link:nth-child(2) a', 0, 200); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 142 |  |  |         $I->click('.ec-footerNavi .ec-footerNavi__link:nth-child(2) a'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 143 |  |  |         $I->see('プライバシーポリシー', 'div.ec-pageHeader h1'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 144 |  |  |         $I->see('個人情報保護の重要性に鑑み、「個人情報の保護に関する法律」及び本プライバシーポリシーを遵守し、お客さまのプライバシー保護に努めます。', 'div.ec-layoutRole__main p:nth-child(1)'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 145 |  |  |     } | 
            
                                                                                                            
                            
            
                                    
            
            
                | 146 |  |  |  | 
            
                                                                                                            
                            
            
                                                                    
                                                                                                        
            
            
                | 147 |  | View Code Duplication |     public function other_特定商取引法に基づく表記(\AcceptanceTester $I) | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 148 |  |  |     { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 149 |  |  |         $I->wantTo('EF0606-UC01-T01 特定商取引法に基づく表記'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 150 |  |  |         $I->amOnPage('/'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 151 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 152 |  |  |         $I->scrollTo('.ec-footerNavi .ec-footerNavi__link:nth-child(3) a', 0, 200); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 153 |  |  |         $I->click('.ec-footerNavi .ec-footerNavi__link:nth-child(3) a'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 154 |  |  |         $I->see('特定商取引法に基づく表記', 'div.ec-pageHeader h1'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 155 |  |  |     } | 
            
                                                                                                            
                            
            
                                    
            
            
                | 156 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 157 |  |  |     public function other_お問い合わせ1(\AcceptanceTester $I) | 
            
                                                                                                            
                            
            
                                    
            
            
                | 158 |  |  |     { | 
            
                                                                                                            
                            
            
                                    
            
            
                | 159 |  |  |         $I->wantTo('EF0607-UC01-T01 お問い合わせ'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 160 |  |  |         $I->amOnPage('/'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 161 |  |  |         $I->resetEmails(); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 162 |  |  |         $faker = Fixtures::get('faker'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 163 |  |  |         $new_email = microtime(true).'.'.$faker->safeEmail; | 
            
                                                                                                            
                            
            
                                    
            
            
                | 164 |  |  |         $BaseInfo = Fixtures::get('baseinfo'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 165 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 166 |  |  |         $I->scrollTo('.ec-footerNavi .ec-footerNavi__link:nth-child(4) a', 0, 200); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 167 |  |  |         $I->click('.ec-footerNavi .ec-footerNavi__link:nth-child(4) a'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 168 |  |  |         $I->see('お問い合わせ', 'div.ec-pageHeader h1'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 169 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 170 |  |  |         $I->fillField(['id' => 'contact_name_name01'], '姓'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 171 |  |  |         $I->fillField(['id' => 'contact_name_name02'], '名'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 172 |  |  |         $I->fillField(['id' => 'contact_kana_kana01'], 'セイ'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 173 |  |  |         $I->fillField(['id' => 'contact_kana_kana02'], 'メイ'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 174 |  |  |         $I->fillField(['id' => 'contact_postal_code'], '530-0001'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 175 |  |  |         $I->selectOption(['id' => 'contact_address_pref'], ['value' => '27']); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 176 |  |  |         $I->fillField(['id' => 'contact_address_addr01'], '大阪市北区'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 177 |  |  |         $I->fillField(['id' => 'contact_address_addr02'], '梅田2-4-9 ブリーゼタワー13F'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 178 |  |  |         $I->fillField(['id' => 'contact_phone_number'], '111-111-111'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 179 |  |  |         $I->fillField(['id' => 'contact_email'], $new_email); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 180 |  |  |         $I->fillField(['id' => 'contact_contents'], 'お問い合わせ内容の送信'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 181 |  |  |         $I->click('div.ec-RegisterRole__actions button.ec-blockBtn--action'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 182 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 183 |  |  |         $I->see('お問い合わせ', 'div.ec-pageHeader h1'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 184 |  |  |         $I->click('div.ec-contactConfirmRole div.ec-RegisterRole__actions button.ec-blockBtn--action'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 185 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 186 |  |  |         // 完了ページ | 
            
                                                                                                            
                            
            
                                    
            
            
                | 187 |  |  |         $I->see('お問い合わせ(完了)', 'div.ec-pageHeader h1'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 188 |  |  |  | 
            
                                                                                                            
                            
            
                                    
            
            
                | 189 |  |  |         // メールチェック | 
            
                                                                                                            
                            
            
                                    
            
            
                | 190 |  |  |         $I->seeEmailCount(2); | 
            
                                                                                                            
                            
            
                                                                    
                                                                                                        
            
            
                | 191 |  | View Code Duplication |         foreach ([$new_email, $BaseInfo->getEmail01()] as $email) { | 
                            
                    |  |  |  | 
                                                                                        
                                                                                     | 
            
                                                                                                            
                            
            
                                    
            
            
                | 192 |  |  |             $I->seeInLastEmailSubjectTo($email, 'お問い合わせを受け付けました'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 193 |  |  |             $I->seeInLastEmailTo($email, '姓 名 様'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 194 |  |  |             $I->seeInLastEmailTo($email, 'お問い合わせ内容の送信'); | 
            
                                                                                                            
                            
            
                                    
            
            
                | 195 |  |  |         } | 
            
                                                                                                            
                            
            
                                    
            
            
                | 196 |  |  |     } | 
            
                                                                                                            
                                                                
            
                                    
            
            
                | 197 |  |  | } | 
            
                                                        
            
                                    
            
            
                | 198 |  |  |  | 
            
                        
Duplicated code is one of the most pungent code smells. If you need to duplicate the same code in three or more different places, we strongly encourage you to look into extracting the code into a single class or operation.
You can also find more detailed suggestions in the “Code” section of your repository.