mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-02-10 10:12:34 -05:00
Add tests to GitHubRemoteBook (#11953)
* Tests for githubRemoteBook class * Add some tests and remove unused class * Address PR comments
This commit is contained in:
@@ -8,7 +8,6 @@ import * as loc from '../common/localizedConstants';
|
||||
import * as vscode from 'vscode';
|
||||
import { RemoteBookDialogModel } from '../dialog/remoteBookDialogModel';
|
||||
import { GitHubRemoteBook } from '../book/githubRemoteBook';
|
||||
import { SharedRemoteBook } from '../book/sharedRemoteBook';
|
||||
import { winPlatform, macPlatform } from '../common/constants';
|
||||
|
||||
const assetNameRE = /([a-zA-Z0-9]+)(?:-|_)([a-zA-Z0-9.]+)(?:-|_)([a-zA-Z0-9]+).(zip|tar.gz|tgz)/;
|
||||
@@ -20,8 +19,6 @@ export class RemoteBookController {
|
||||
public async setRemoteBook(url: vscode.Uri, remoteLocation: string, asset?: IAsset): Promise<void> {
|
||||
if (remoteLocation === 'GitHub') {
|
||||
this.model.remoteBook = new GitHubRemoteBook(url, this.outputChannel, asset);
|
||||
} else {
|
||||
this.model.remoteBook = new SharedRemoteBook(url, this.outputChannel);
|
||||
}
|
||||
return await this.model.remoteBook.createLocalCopy();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user