File tree Expand file tree Collapse file tree 2 files changed +7
-6
lines changed
Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Original file line number Diff line number Diff line change 1- import { startServer , stopServer } from "nativescript-dev-appium" ;
1+ import { startServer , stopServer , createDriver } from "nativescript-dev-appium" ;
22
3+ let driver ;
34before ( "start server" , async ( ) => {
45 await startServer ( ) ;
6+ driver = await createDriver ( ) ;
57} ) ;
68
79after ( "stop server" , async ( ) => {
10+ try {
11+ await driver . logTestArtifacts ( this . currentTest . title ) ;
12+ await driver . quit ( ) ;
13+ } catch ( error ) { }
814 await stopServer ( ) ;
915} ) ;
Original file line number Diff line number Diff line change @@ -17,11 +17,6 @@ describe("smoke-tests", () => {
1717 driver = await createDriver ( ) ;
1818 } ) ;
1919
20- after ( async ( ) => {
21- await driver . quit ( ) ;
22- console . log ( "Quit driver!" ) ;
23- } ) ;
24-
2520 afterEach ( async function ( ) {
2621 if ( this . currentTest . state === "failed" ) {
2722 await driver . logTestArtifacts ( this . currentTest . title ) ;
You can’t perform that action at this time.
0 commit comments