mirror of
https://github.com/kubescape/kubescape.git
synced 2026-04-15 06:58:11 +00:00
Wrote ne tsts for the following packages: - completion - config - download - fix - list Also addressed a potential crash in the compleition, download, and list subcommands when no arguement was provided to the Args, RunE or Run functions. Updated `DownloadSupportCommands`, 'ListSupportActions' function to return sorted slice of strings. Signed-off-by: VaibhavMalik4187 <vaibhavmalik2018@gmail.com>
Kubescape core package
// initialize kubescape
ks := core.NewKubescape()
// scan cluster
results, err := ks.Scan(&cautils.ScanInfo{})
// convert scan results to json
jsonRes, err := results.ToJson()