Cov txheej txheem:

Dab tsi yog hooks hauv dib?
Dab tsi yog hooks hauv dib?

Video: Dab tsi yog hooks hauv dib?

Video: Dab tsi yog hooks hauv dib?
Video: Wen - Kuv Yog Dab Tsi Tiag - New hmong Song ( Audio ) Hip Hop - เลับเปีด 2024, Lub Xya hli ntuj
Anonim

Dib txhawb nqa nuv , uas yog cov lej ntawm cov cai uas ua ntej lossis tom qab txhua qhov xwm txheej. Koj tuaj yeem txhais lawv nyob txhua qhov chaw hauv koj txoj haujlwm lossis qib txhais cov txheej txheem, siv cov txheej txheem @Before thiab @After. Cucumber Hooks tso cai rau peb los tswj cov txheej txheem ua haujlwm tau zoo dua qub thiab pab peb kom txo cov lej rov ua dua tshiab.

Yog li ntawd, dab tsi yog qhov nuv ntses hauv dib?

Dib txhawb nqa nuv , uas yog cov lej ntawm cov cai uas ua ntej lossis tom qab txhua qhov xwm txheej. Koj tuaj yeem txhais lawv nyob txhua qhov chaw hauv koj txoj haujlwm lossis qib txhais cov txheej txheem, siv cov txheej txheem @Before thiab @After. Cucumber Hooks tso cai rau peb los tswj cov txheej txheem ua haujlwm tau zoo dua qub thiab pab peb kom txo cov lej rov ua dua tshiab.

Tsis tas li, dab tsi yog daim ntawv hauv dib? Hauv Dib , cim npe yog siv los koom nrog ib qho kev sim xws li haus luam yeeb, regression thiab lwm yam nrog rau ib qho xwm txheej.

Kuj paub, koj ua li cas muab tus nuv rau ntawm dib?

Dib - Hooks

  1. Kauj Ruam 1 - Tsim Maven qhov project li nuvTest, ntxiv qhov tsim nyog nyob hauv pom.
  2. Kauj Ruam 2 - Tsim Java pob npe hu ua hookTest hauv src/test/java.
  3. Kauj Ruam 3 - Tsim cov txheej txheem txhais cov npe hu ua hookTest.
  4. Kauj ruam 4 - Tsim cov ntaub ntawv feature hu ua "hookTest.
  5. Feature - Txheej txheem cej luam.
  6. Scenario Tus Txheej Txheem - Nuv Ntses.

Dab tsi ua ntej hauv cov ntaub ntawv hooks?

Raws li lub npe qhia, @ ua ntej nuv tau raug tua zoo ua ntej lwm qhov xwm txheej sim, thiab @after nuv tau raug tua tom qab ua tiav qhov scenario.

Pom zoo: