Skip to content

Commit

Permalink
test: update tests
Browse files Browse the repository at this point in the history
  • Loading branch information
sjinks committed Dec 10, 2024
1 parent d5271bd commit 572cfff
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion __tests__/commands/dev-env-sync-sql.ts
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,10 @@ describe( 'commands/DevEnvSyncSQLCommand', () => {
blogId: 3,
homeUrl: 'https://another.com/path',
},
{
blogId: 4,
homeUrl: 'https://test.go-vip.com/path',
},
],
},
};
Expand Down Expand Up @@ -73,13 +77,14 @@ describe( 'commands/DevEnvSyncSQLCommand', () => {
it( 'should return a map of search-replace values for multisite', () => {
const cmd = new DevEnvSyncSQLCommand( app, msEnv, 'test-slug', lando );
cmd.slug = 'test-slug';
cmd.siteUrls = [ 'https://test.go-vip.com', 'http://subsite.com', 'http://another.com/path' ];
cmd.siteUrls = msEnv.wpSitesSDS.nodes.map( node => node.homeUrl );
cmd.generateSearchReplaceMap();

expect( cmd.searchReplaceMap ).toEqual( {
'test.go-vip.com': 'test-slug.vipdev.lndo.site',
'subsite.com': 'subsite-com.test-slug.vipdev.lndo.site',
'another.com/path': 'another-com.test-slug.vipdev.lndo.site/path',
'test.go-vip.com/path': 'test-slug.vipdev.lndo.site/path',
} );
} );
} );
Expand Down

0 comments on commit 572cfff

Please sign in to comment.