summaryrefslogtreecommitdiff
diff options
authorPaweł Stołowski <stolowski@gmail.com>2022-04-19 18:20:26 +0200
committerPaweł Stołowski <stolowski@gmail.com>2022-04-19 18:20:26 +0200
commit8b221122eeea43c37e5fb97f3f51b4b39093cac1 (patch)
tree8f20947294fd8dd47b630ae2897e74b3800ba99e
parent11abfd8813b6a7f3112b6e4c32bd58f7c2a3e923 (diff)
Add missing docstring.tooling-store-pkg
-rw-r--r--store/tooling/tooling.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/store/tooling/tooling.go b/store/tooling/tooling.go
index 8af14948b7..b22f047434 100644
--- a/store/tooling/tooling.go
+++ b/store/tooling/tooling.go
@@ -194,6 +194,7 @@ func (tac toolingStoreContext) UpdateUserAuth(user *auth.UserState, discharges [
return user, nil
}
+// NewToolingStoreFromModel creates ToolingStore for the snap store used by the given model.
func NewToolingStoreFromModel(model *asserts.Model, fallbackArchitecture string) (*ToolingStore, error) {
architecture := model.Architecture()
// can happen on classic
@@ -477,6 +478,7 @@ func (tsto *ToolingStore) Find(at *asserts.AssertionType, headers map[string]str
// MockToolingStore creates a ToolingStore that uses the provided StoreImpl
// implementation for Download, SnapAction and Assertion methods.
+// For testing.
func MockToolingStore(sto StoreImpl) *ToolingStore {
return &ToolingStore{sto: sto}
}