store: move adding the local target to weldr
The automatic local target is only needed when accessing the API via weldr. In the store, the target was only added when `stateDir` was not `nil`. This is only used for testing which doesn't exercise the branch in weldr. Thus, the same check is not needed there.
This commit is contained in:
parent
7594cb262e
commit
3544590036
3 changed files with 30 additions and 16 deletions
|
|
@ -476,7 +476,15 @@ func TestCompose(t *testing.T) {
|
|||
{
|
||||
QueueStatus: common.IBWaiting,
|
||||
ImageType: common.Qcow2Generic,
|
||||
Targets: []*target.Target{},
|
||||
Targets: []*target.Target{
|
||||
{
|
||||
// skip Uuid and Created fields - they are ignored
|
||||
Name: "org.osbuild.local",
|
||||
Options: &target.LocalTargetOptions{
|
||||
Filename: "test.img",
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
|
|
@ -507,6 +515,13 @@ func TestCompose(t *testing.T) {
|
|||
Key: "imagekey",
|
||||
},
|
||||
},
|
||||
{
|
||||
// skip Uuid and Created fields - they are ignored
|
||||
Name: "org.osbuild.local",
|
||||
Options: &target.LocalTargetOptions{
|
||||
Filename: "test.img",
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue