[prev in list] [next in list] [prev in thread] [next in thread]
List: openembedded-core
Subject: [OE-core] [PATCH 13/23] oeqa/core/utils/misc: remove redundant file
From: "Ross Burton" <ross () burtonini ! com>
Date: 2022-03-31 18:29:05
Message-ID: 20220331182915.22128-13-ross.burton () arm ! com
[Download RAW message or body]
Content-Transfer-Encoding: quoted-printable
This file dates back to 2016. Half of the functions have never been used,
the rest are used in one place and have now been replaced.
Signed-off-by: Ross Burton <ross.burton@arm.com>
---
meta/lib/oeqa/core/utils/misc.py | 47 --------------------------------
1 file changed, 47 deletions(-)
delete mode 100644 meta/lib/oeqa/core/utils/misc.py
diff --git a/meta/lib/oeqa/core/utils/misc.py b/meta/lib/oeqa/core/utils/misc.py
deleted file mode 100644
index e1a59588eb6..00000000000
--- a/meta/lib/oeqa/core/utils/misc.py
+++ /dev/null
@@ -1,47 +0,0 @@
-#
-# Copyright (C) 2016 Intel Corporation
-#
-# SPDX-License-Identifier: MIT
-#
-
-def toList(obj, obj_type, obj_name="Object"):
- if isinstance(obj, obj_type):
- return [obj]
- elif isinstance(obj, list):
- return obj
- else:
- raise TypeError("%s must be %s or list" % (obj_name, obj_type))
-
-def toSet(obj, obj_type, obj_name="Object"):
- if isinstance(obj, obj_type):
- return {obj}
- elif isinstance(obj, list):
- return set(obj)
- elif isinstance(obj, set):
- return obj
- else:
- raise TypeError("%s must be %s or set" % (obj_name, obj_type))
-
-def strToList(obj, obj_name="Object"):
- return toList(obj, str, obj_name)
-
-def strToSet(obj, obj_name="Object"):
- return toSet(obj, str, obj_name)
-
-def intToList(obj, obj_name="Object"):
- return toList(obj, int, obj_name)
-
-def dataStoteToDict(d, variables):
- data = {}
-
- for v in variables:
- data[v] = d.getVar(v)
-
- return data
-
-def updateTestData(d, td, variables):
- """
- Updates variables with values of data store to test data.
- """
- for var in variables:
- td[var] = d.getVar(var)
--
2.25.1
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#163854): https://lists.openembedded.org/g/openembedded-core/message/163854
Mute This Topic: https://lists.openembedded.org/mt/90161348/4454766
Group Owner: openembedded-core+owner@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [openembedded-core@marc.info]
-=-=-=-=-=-=-=-=-=-=-=-
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic