aboutsummaryrefslogtreecommitdiffstats
path: root/tests/test_subscriber.vty.sql
diff options
context:
space:
mode:
authorOliver Smith <osmith@sysmocom.de>2019-01-22 14:44:28 +0100
committerHarald Welte <laforge@gnumonks.org>2019-01-24 15:29:08 +0000
commitef64b231dc4a385c471754440d89d35f091fea27 (patch)
tree5b06744610115f93527ca44ae26ac5b93978dbdc /tests/test_subscriber.vty.sql
parent851814aa7c6a89faa536d5ec60d16dd37826e2d0 (diff)
VTY tests: fill DB before running test
Create a test_subscriber.vty.sql file with a dummy entry that has the ID 100. All entries created in test_subscriber.vty have an ID > 100 now. This will be used in follow-up commit [1] to create a database entry with an invalid IMEI value to test the related error handling code path (that entry could not be created through the VTY). [1]: change-id I1af7b573ca2a1cb22497052665012d9c1acf3b30 "VTY: integrate IMEI" Related: OS#3733 Change-Id: I48a3a503d7ca96798e2d5f70429b5fc36393420e
Diffstat (limited to 'tests/test_subscriber.vty.sql')
-rw-r--r--tests/test_subscriber.vty.sql3
1 files changed, 3 insertions, 0 deletions
diff --git a/tests/test_subscriber.vty.sql b/tests/test_subscriber.vty.sql
new file mode 100644
index 0000000..ff167aa
--- /dev/null
+++ b/tests/test_subscriber.vty.sql
@@ -0,0 +1,3 @@
+-- Dummy entry with ID=100 gives all subscribers created in the VTY test an
+-- ID > 100, so we can pre-fill the database with IDs < 100.
+INSERT INTO subscriber (id, imsi) VALUES(100, '000000000000100');