Contents

Generating Personas

Scenario: Deleting old Datasets

@generating_personas

  • Given no dump is existing

Scenario: Genarating Minimal Dataset

@generating_personas

  • Given the minimal setup exists
  • And the item fields are initialized
  • Then there are 45 fields in total
  • And the ZHdK item fields are initialized
  • Then there are 51 fields in total
  • Then the minimal dump is generated

Scenario: Genarating Dataset 1

@generating_personas

  • Given today is a random date
  • And the minimal dump is loaded
  • And the following users exist
    firstnamelastnameemaillanguageaddress
    Gino#{Faker::Name.last_name}gino@zhdk.chen-GB
    Ramon#{Faker::Name.last_name}ramon@zhdk.chen-GB
    Matti#{Faker::Name.last_name}matti@zhdk.chen-GB
    Mike#{Faker::Name.last_name}mike@zhdk.chen-GB
    Pius#{Faker::Name.last_name}pius@zhdk.chen-GB
    NorminNormalonormin@zhdk.chen-GB
    #{Faker::Name.first_name}#{Faker::Name.last_name}lending_manager1@zhdk.chen-GB
    PeterSiliepeter@silie.comen-GB
    Andi#{Faker::Name.last_name}andi@zhdk.chen-GB
    Mina#{Faker::Name.last_name}mina@zhdk.chen-GB
    Petra#{Faker::Name.last_name}petra@zhdk.chen-GB#{Faker::Address.street_address + ", "}
    Julie#{Faker::Name.last_name}julie@zhdk.ch
    Lisa#{Faker::Name.last_name}lisa@zhdk.chen-GB
    #{Faker::Name.first_name}#{Faker::Name.last_name}customer1@zhdk.ch
    #{Faker::Name.first_name}#{Faker::Name.last_name}customer2@zhdk.ch
    #{Faker::Name.first_name}#{Faker::Name.last_name}customer3@zhdk.ch
    #{Faker::Name.first_name}#{Faker::Name.last_name}customer4@zhdk.ch
    #{Faker::Name.first_name}#{Faker::Name.last_name}customer5@zhdk.ch
    #{Faker::Name.first_name}#{Faker::Name.last_name}customer6@zhdk.ch
    #{Faker::Name.first_name}#{Faker::Name.last_name}customer7@zhdk.ch
    #{Faker::Name.first_name}#{Faker::Name.last_name}customer8@zhdk.ch
    #{Faker::Name.first_name}#{Faker::Name.last_name}customer9@zhdk.ch
    #{Faker::Name.first_name}#{Faker::Name.last_name}delegator1@zhdk.ch
    #{Faker::Name.first_name}#{Faker::Name.last_name}delegated1@zhdk.ch
  • And 1 user exists
  • Then there are 25 users in total
  • And the following inventory pools exist
    nameshortnameemaildescriptioncontact_detailscontract_descriptionautomatic_suspension
    A-AusleiheAa@zhdk.chWichtige Hinweise...\n\nBitte die Gegenstände rechtzeitig zurückbringenA Verleih / ZHdK\na@zh-dk.ch\n\n+41 00 00 00 00Gerät erhaltentrue
    IT-AusleiheITit@zhdk.chBringt die Geräte bitte rechtzeitig zurückIT Verleih / ZHdK\nit@zh-dk.ch\n\n+41 00 00 00 00Gerät erhaltentrue
    AV-TechnikAVav@zhdk.chBringt die Geräte bitte rechtzeitig zurückAV Verleih / ZHdK\nav@zh-dk.ch\n\n+41 00 00 00 00Gerät erhaltenfalse
    DT deletableDTit@zhdk.chGerät erhaltenfalse
  • Then there are 4 inventory pools in total
  • And the following delegations exist
    delegator user emailname
    julie@zhdk.chDelegation 1
    mina@zhdk.chDelegation 2
    mina@zhdk.chDelegation 3
    mina@zhdk.chDelegation 4
    delegator1@zhdk.chDelegation 5
  • Then there are 5 delegations in total
  • And the following delegations have following delegated users
    delegation nameuser email
    Delegation 1mina@zhdk.ch
    Delegation 2julie@zhdk.ch
    Delegation 3julie@zhdk.ch
    Delegation 4julie@zhdk.ch
    Delegation 5delegated1@zhdk.ch
  • And the following access rights exist
    user emaildelegation nameroleinventory pooldeleted atsuspended untilsuspended reason
    gino@zhdk.chadmin
    ramon@zhdk.chadmin
    ramon@zhdk.chcustomerA-Ausleihe
    matti@zhdk.chinventory_managerIT-Ausleihe
    mike@zhdk.chinventory_managerA-Ausleihe
    mike@zhdk.chinventory_managerDT deletable
    pius@zhdk.chlending_managerA-Ausleihe
    pius@zhdk.chlending_managerIT-Ausleihe
    lending_manager1@zhdk.chlending_managerA-Ausleihe
    lending_manager1@zhdk.chlending_managerIT-Ausleihe
    peter@silie.comcustomerA-Ausleihe
    normin@zhdk.chcustomerA-Ausleihe
    normin@zhdk.chcustomerIT-Ausleihe
    normin@zhdk.chcustomerAV-Technik
    normin@zhdk.chcustomerDT deletable#{Date.yesterday}
    andi@zhdk.chgroup_managerA-Ausleihe
    andi@zhdk.chgroup_managerIT-Ausleihe
    andi@zhdk.chgroup_managerAV-Technik
    mina@zhdk.chcustomerA-Ausleihe
    petra@zhdk.chcustomerA-Ausleihe
    julie@zhdk.chcustomerA-Ausleihe
    lisa@zhdk.chcustomerA-Ausleihe
    Delegation 1customerA-Ausleihe
    Delegation 2customerA-Ausleihe
    Delegation 2customerIT-Ausleihe
    Delegation 4customerA-Ausleihe
    Delegation 4customer
    Delegation 4customer
    Delegation 5customerA-Ausleihe
    delegator1@zhdk.chcustomerA-Ausleihe
    delegated1@zhdk.chcustomerA-Ausleihe
    customer1@zhdk.chcustomerA-Ausleihe
    customer2@zhdk.chcustomerA-Ausleihe#{Date.today}#{Faker::Lorem.sentence}
    customer3@zhdk.chcustomerA-Ausleihe
    customer4@zhdk.chcustomerA-Ausleihe
    customer5@zhdk.chcustomerA-Ausleihe
    customer6@zhdk.chcustomerA-Ausleihe
    customer7@zhdk.chcustomerA-Ausleihe
    customer8@zhdk.chcustomerA-Ausleihe
    customer9@zhdk.chcustomerA-Ausleihe
  • And users with the following access rights exist
    roleinventory pool
    customerAV-Technik
    lending_managerA-Ausleihe
    group_managerA-Ausleihe
  • Then there are 43 access rights in total
  • Then there are 6 inventory pools in total
  • Then there are 6 workdays in total
  • And the following workdays exist
    inventory poolmondaytuesdaywednesdaythursdayfridaysaturdaysundayreservation_advance_daysmax_visits
    A-Ausleihe11111000{"1": 10, "2": 20, "3": 30}
  • Then there are 6 workdays in total
  • And the following holidays exist
    inventory poolnamestart dateend date
    A-AusleiheChristmas24.12.xxxx26.12.xxxx
    IT-AusleiheChristmas24.12.xxxx26.12.xxxx
    AV-TechnikChristmas24.12.xxxx26.12.xxxx
  • Then there are 6 holidays in total
  • And the following building exists:
    namecode
    Ausstellungsstrasse 60AU60
  • Then there are 1 buildings in total
  • And the following location exists:
    roomshelfbuilding code
    SQ2DeskAU60
    UG 13AusgabeAU60
  • Then there are 2 locations in total
  • Then there are 0 models in total
  • And the following models exist:
    productversionmanufacturerdescriptionhand over notemaintenance period
    MacBookProAppleLaptop für Studis und Angestellte.Mit Verpackung aushändigen.0
    Sharp Beamer123SharpBeamer, geeignet für alle Verwendungszwecke.Beamer braucht ein VGA Kabel!0
    Sharp Beamer 2DSharpBeamer, geeignet für alle Verwendungszwecke.0
    Mini BeamerPanasonicBeamer, geeignet für alle Verwendungszwecke.0
    Sharp Beamer456PanasonicBeamer, geeignet für alle Verwendungszwecke.Beamer braucht ein VGA Kabel!0
    Ultra Compact BeamerSonyBesonders kleiner Beamer.Beamer braucht ein VGA Kabel!0
    Micro BeamerMicroBesonders mikro kleiner Beamer.Beamer braucht ein VGA Kabel!0
    Kamera NikonX12NikonSuper Kamera.Kamera braucht Akkus!0
    Kamera Stativ123FeliStabiles Kamera StativStativ muss mit Stativtasche ausgehändigt werden.0
    Hifi StandardSony
    Bose AE2WBose#{Faker::Lorem.paragraph}
    Bose XG4Bose#{Faker::Lorem.paragraph}
    Kamera Canon D5CanonGanz teure KameraKamera braucht Akkus!0
    Windows LaptopMicrosoftEin Laptop der Marke MicrosoftLaptop mit Tasche ausgeben0
    Walkera v1201GWalkera3D Helikopter0
    Walkera v1202GWalkera3D Helikopter0
    Walkera v1203GWalkera3D Helikopter0
    iMacAppleApples alter iMac0
    MacBook AirApple0
    ThinkpadX230Lenovo0
    ThinkpadX301Lenovo0
    ThinkpadCarbonLenovo0
    Inspiron7000Dell0
  • Then there are 23 models in total
  • Then there are 0 items in total
  • And the following categories exist:
    nameparent name
    Beamer
    Kameras
    Stative
    Hifi-Anlagen
    Notebooks
    RC Helikopter
    Computer
    KurzdistanzKameras
    PortabelNotebooks
    PortabelBeamer
    StandardKameras
    StandardNotebooks
    MicroPortabel
  • Then there are 11 categories in total
  • And there exists 20 models of category "Beamer" each with 1 item with following properties:
    model namemodel manufacturermodel hand over notelocation roomlocation shelfbuilding codeinventory pool
    BeamerSonyBeamer braucht ein VGA Kabel!SQ2DeskAU60A-Ausleihe
  • Then there are 43 models in total
  • Then there are 20 items in total
  • And there exists 30 models of category "Kameras" each with 1 item with following properties:
    model namemodel manufacturermodel hand over notelocation roomlocation shelfbuilding codeinventory pool
    CameraNikonSQ2DeskAU60A-Ausleihe
  • Then there are 73 models in total
  • Then there are 50 items in total
  • And the category "Kameras" has 1 image
  • And the following categories have the following models:
    category namemodel name
    NotebooksMacBookPro
    BeamerSharp Beamer 123
    PortabelSharp Beamer 123
    BeamerSharp Beamer 2D
    BeamerMini Beamer
    BeamerUltra Compact Beamer
    PortabelUltra Compact Beamer
    MicroMicro Beamer
    KamerasKamera Nikon
    StativeKamera Stativ
    Hifi-AnlagenHifi Standard
    KamerasKamera Canon D5
    NotebooksWindows Laptop
    RC HelikopterWalkera v120 1G
    RC HelikopterWalkera v120 2G
    RC HelikopterWalkera v120 3G
    ComputeriMac
  • And the model "Walkera v120 1G" has the following properties:
    keyvalue
    Rotordurchmesser120
    Akkus2
    FarbeRot
  • And the model "Walkera v120 2G" has the following properties:
    keyvalue
    Rotordurchmesser120
    Akkus2
    FarbeRot
    max. Speed80 kmh
    GyroJa
    Achsen3-Achsen
  • And the model "Walkera v120 3G" has the following properties:
    keyvalue
    Rotordurchmesser120
    Akkus2
    FarbeRot
  • And the model "Walkera v120 1G" has the following compatibles:
    model name
    Windows Laptop
  • And the model "Walkera v120 2G" has the following compatibles:
    model name
    Windows Laptop
  • And the model "Walkera v120 3G" has the following compatibles:
    model name
    Windows Laptop
  • And the model "Walkera v120 2G" has 1 attachment
  • And the model "Walkera v120 3G" has 1 attachment
  • And the model "Walkera v120 2G" has 2 images
  • And the model "Walkera v120 3G" has 1 image
  • And each of the models has from 1 to 5 accessories possibly activated for the inventory pool "A-Ausleihe"
  • And the following items exist:
    inventory codeserial numberproduct namenameretiredretired reasonis borrowableis brokenis incompleteinventory pool nameowner namelocation roomlocation shelfbuilding code
    book1book1MacBookProIT-AusleiheSQ2DeskAU60
    book2book2MacBookProIT-AusleiheSQ2DeskAU60
    beam123xyz456Sharp Beamer 123A-AusleiheSQ2DeskAU60
    beam345xyz890Sharp Beamer 123A-AusleiheSQ2DeskAU60
    beam678xyz678Sharp Beamer 2DA-AusleiheSQ2DeskAU60
    beam749xyz749Sharp Beamer 123IT-AusleiheA-AusleiheSQ2DeskAU60
    beamTest123xyz74912Sharp Beamer 456A-AusleiheSQ2DeskAU60
    ucbeam1minbeam1Ultra Compact Beamerucbeam1A-AusleiheSQ2DeskAU60
    microbeam1microbeam1Micro Beamermicrobeam1A-AusleiheSQ2DeskAU60
    cam123abc234Kamera NikonA-AusleiheSQ2DeskAU60
    cam345ab567Kamera NikonA-AusleiheSQ2DeskAU60
    cam567ab789Kamera NikonA-AusleiheSQ2DeskAU60
    cam53267ab782129Kamera NikonA-AusleiheSQ2DeskAU60
    cam532asd67ab78as2129Kamera NikonA-AusleiheSQ2DeskAU60
    tri789fgh567Kamera StativA-AusleiheSQ2DeskAU60
    tri123fgh987Kamera StativA-AusleiheSQ2DeskAU60
    tri923asd213Kamera StativA-AusleiheSQ2DeskAU60
    tri212tri212Kamera StativA-AusleiheSQ2DeskAU60
    hifi123hifi123Hifi StandardA-AusleiheSQ2DeskAU60
    bose123bose123Bose XG4A-AusleiheSQ2DeskAU60
    cand5cand5Kamera NikonfalseA-AusleiheSQ2DeskAU60
    beam21231beamas12312Sharp Beamer 123falseA-AusleiheSQ2DeskAU60
    hifi345hifi345Hifi StandardfalseA-AusleiheSQ2DeskAU60
    wlaptop1wlaptop1Windows LaptoptrueA-AusleiheSQ2DeskAU60
    v120d02v120d02Walkera v120 1GtrueA-AusleiheSQ2DeskAU60
    v120d11v120d11Walkera v120 1G#{Date.today}#{Faker::Lorem.sentence}falsetruetrueA-Ausleihe
    v120d022gv120d022gWalkera v120 2GA-AusleiheSQ2DeskAU60
    v120d022g2v120d022g2Walkera v120 2GA-AusleiheSQ2DeskAU60
    iMac1iMac1iMac#{Date.today}This item is gone.A-AusleiheSQ2DeskAU60
    iMac2iMac2iMac#{Date.today}This item is gone.A-AusleiheAV-TechnikSQ2DeskAU60
    lpv3yclpv3ycBose AE2W#{Date.today}This item is gone.A-AusleiheSQ2DeskAU60
    6cxjcs6cxjcsBose AE2W#{Date.today}This item is gone.A-AusleiheSQ2DeskAU60
    beam897beam897Sharp Beamer 123IT-AusleiheSQ2DeskAU60
    minibeam12minibeam12Mini BeamerIT-AusleiheSQ2DeskAU60
    minibeam34minibeam34Mini BeamerAV-TechnikSQ2DeskAU60
    minibeam56minibeam56Mini BeamerA-AusleiheSQ2DeskAU60
    minibeam78minibeam78Mini BeamerA-AusleiheSQ2DeskAU60
    air123air123MacBook AirA-AusleiheSQ2DeskAU60
    tp230tp230Thinkpad X230A-AusleiheSQ2DeskAU60
    tp301tp301Thinkpad X301A-AusleiheSQ2DeskAU60
    carbon1carbon1Thinkpad CarbonA-AusleiheSQ2DeskAU60
    carbon2carbon2Thinkpad CarbonA-AusleiheSQ2DeskAU60
    inspiron1inspiron1Inspiron 7000A-AusleiheSQ2DeskAU60
    IT-AusleiheA-AusleiheSQ2DeskAU60
  • Then there are 94 items in total
  • Then there are 5 retired items in total
  • Then there are 2 broken items in total
  • Then there are 2 incomplete items in total
  • And the following software exists:
    producttechnical detail
    Adobe Acrobattest http://test.ch\r\nwww.foo.ch\r\njust a text
    MS Wordtest http://test.ch\r\nwww.foo.ch\r\njust a text
  • And the software "Adobe Acrobat" has from 1 to 3 attachments
  • And the software "MS Word" has from 1 to 3 attachments
  • And there exist more than 2 and less then 6 arbitrary licenses for the inventory pool "A-Ausleihe"
  • And the following licenses exist:
    inventory codesoftware nameowner nameinventory pool nameis borrowableretiredretired reasoninvoice datelicense expirationmaintenance contractmaintenance expirationoperating systemlicense typetotal quantity
    A-AusleiheIT-Ausleihe#{[true, false].sample}
    A-Ausleihe#{[true, false].sample}#{Date.today}#{Faker::Lorem.sentence}
    IT-AusleiheA-Ausleihe#{[true, false].sample}#{Date.today}#{Faker::Lorem.sentence}
    IT-Ausleihetrue
    A-Ausleihe#{[true, false].sample}#{Date.today}#{Date.today}true#{Date.today}
    acrobat123Adobe AcrobatA-Ausleihe#{[true, false].sample}
    msword123A-Ausleihe#{[true, false].sample}#{%w(windows linux mac_os_x).sample(rand(1..2)).join(',')}#{%w(concurrent site_license multiple_workplace).sample}#{rand(300)}
    lic111A-AusleiheIT-Ausleihe#{[true, false].sample}#{%w(windows linux mac_os_x).sample(rand(1..2)).join(',')}#{%w(concurrent site_license multiple_workplace).sample}#{rand(300)}
    A-AusleiheA-Ausleihe#{[true, false].sample}#{%w(windows linux mac_os_x).sample(rand(1..2)).join(',')}#{%w(concurrent site_license multiple_workplace).sample}#{rand(300)}
  • And the license with inventory code "acrobat123" has to following quantity allocations:
    roomquantity
    #{Faker::Lorem.word}#{rand(1..50)}
    #{Faker::Lorem.word}#{rand(1..50)}
  • And the license with inventory code "msword123" has to following quantity allocations:
    roomquantity
    #{Faker::Lorem.word}#{rand(1..50)}
    #{Faker::Lorem.word}#{rand(1..50)}
  • And the following package model with 3 items exists:
    product nameinventory pool name
    Kamera SetA-Ausleihe
  • And the following package model with 1 item exists:
    product nameinventory pool name
    Kamera SetIT-Ausleihe
  • And the following package model with 3 items exists:
    product nameinventory pool name
    Kamera Set2A-Ausleihe
  • Then there are 2 package models in total
  • And the following options exist:
    inventory codeproduct nameinventory pool name
    akku-aaAkku AAA-Ausleihe
    akku-aaaAkku AAAA-Ausleihe
    usbUSB KabelA-Ausleihe
    sandsack123SandsackA-Ausleihe
  • Then there are 4 options in total
  • And template "Kamera & Stativ" with the following quantities exists:
    model namequantity
    Kamera Nikon1
    Kamera Stativ1
  • And the template "Kamera & Stativ" is used in the inventory pool "A-Ausleihe"
  • And template "Beamer & Hifi" with the following quantities exists:
    model namequantity
    Sharp Beamer 1231
    Hifi Standard1
  • And the template "Beamer & Hifi" is used in the inventory pool "A-Ausleihe"
  • And template "Unaccomplishable template" with the following quantities exists:
    model namequantity
    Kamera Nikon999
    Kamera Stativ999
  • And the template "Unaccomplishable template" is used in the inventory pool "A-Ausleihe"
  • Then there are 3 templates in total
  • And the following groups exist:
    nameinventory poolverification required
    CastA-Ausleihefalse
    IADA-Ausleihefalse
    WuA-Ausleihefalse
    Group HifiA-Ausleihefalse
    Group AA-Ausleihefalse
    Group BA-Ausleihefalse
    FFIA-Ausleihetrue
    VTOA-Ausleihetrue
    1. SemesterIT-Ausleihetrue
    Group CA-Ausleihefalse
  • Then there are 10 groups in total
  • And the group "Cast" hast following users:
    user email
    normin@zhdk.ch
    lisa@zhdk.ch
  • And the group "FFI" hast following users:
    user email
    customer1@zhdk.ch
    customer2@zhdk.ch
    customer3@zhdk.ch
    customer4@zhdk.ch
    customer5@zhdk.ch
  • And the group "VTO" hast following users:
    user email
    customer1@zhdk.ch
    customer3@zhdk.ch
  • And the group "1. Semester" hast following users:
    user email
    customer4@zhdk.ch
  • And the group "Group C" hast following users:
    user email
    customer6@zhdk.ch
  • And the following partitions exist:
    inventory pool namegroup namemodel namequantity
    A-AusleiheGroup HifiHifi Standard1
    A-AusleiheCastKamera Nikon X121
    A-AusleiheIADKamera Nikon X121
    A-AusleiheCastWalkera v120 1G1
    A-AusleiheGroup AWalkera v120 2G1
    A-AusleiheGroup BWalkera v120 3G5
    A-AusleiheFFIMacBook Air1
    A-AusleiheFFIThinkpad X3011
    A-AusleiheVTOThinkpad X2301
    A-AusleiheGroup CThinkpad Carbon1
  • Then there are 10 partitions in total
  • And 3 unsubmitted contract reservation exists
  • And 3 unsubmitted contract reservation for user "normin@zhdk.ch" exists
  • And all unsubmitted contract reservations are available
  • And 3 to 5 submitted item reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeBenötige ich für die Aufnahmen meiner Abschlussarbeit.
    start date#{Date.today + 7.days}
    end date#{Date.today + 10.days}
    model nameKamera Nikon X12
  • And 3 to 5 submitted item reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeBenötige ich für die Aufnahmen meiner Abschlussarbeit.
    start date#{Date.today + 7.days}
    end date#{Date.today + 10.days}
    model nameKamera Stativ 123
  • And 1 to 1 submitted item reservations with following properties exists:
    user emailcustomer6@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedfalse
    model nameThinkpad Carbon
    start date#{Date.today}
    end date#{Date.today + 1.day}
  • And 4 submitted contract reservations for user "normin@zhdk.ch" exist
  • And today is "#{Time.now - rand(1..7).days}"
  • And 3 to 5 submitted item reservations with following properties exists:
    user emailcustomer1@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
  • And 1 to 1 submitted item reservations with following properties exists:
    user emailcustomer1@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
    model nameMacBook Air
  • And today is back to initial random date
  • And 3 to 5 submitted item reservations with following properties exists:
    user emailcustomer2@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
  • And 1 to 1 submitted item reservations with following properties exists:
    user emailcustomer2@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
    model nameThinkpad X301
  • And 3 to 5 submitted item reservations with following properties exists:
    user emailcustomer3@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
  • And 3 to 5 submitted item reservations with following properties exists:
    user emailcustomer4@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
  • And 3 to 5 submitted item reservations with following properties exists:
    user emailcustomer5@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
  • And today is "#{Time.now - rand(1..7).days}"
  • And 3 to 5 submitted item reservations with following properties exists:
    user emailcustomer1@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
  • And 2 to 2 submitted item reservations with following properties exists:
    user emailcustomer1@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
    model nameThinkpad X230
  • And today is back to initial random date
  • And today is "#{Time.now - rand(1..7).days}"
  • And 3 to 5 submitted item reservations with following properties exists:
    user emailcustomer1@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
  • And today is back to initial random date
  • And 1 to 1 submitted item reservations with following properties exists:
    user emailpetra@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeFür meinen aktuellen Kurs.
    start date#{Date.today + 7.days}
    end date#{Date.today + 10.days}
    model nameKamera Nikon X12
  • And 1 to 1 submitted item reservations with following properties exists:
    user emailpetra@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeFür meinen aktuellen Kurs.
    start date#{Date.today + 7.days}
    end date#{Date.today + 10.days}
    model nameKamera Stativ 123
  • And 1 to 1 submitted item reservations with following properties exists:
    user emailpetra@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeFür meinen aktuellen Kurs.
    start date#{Date.today + 8.days}
    end date#{Date.today + 11.days}
    model nameKamera Stativ 123
  • And 1 to 1 submitted item reservations with following properties exists:
    user emailpetra@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeFür meinen aktuellen Kurs.
    start date#{Date.today}
    end date#{Date.today + 1.days}
    model nameUltra Compact Beamer
  • And 1 approved contract reservation exists
  • And 30 to 40 approved item reservations with following properties exists:
    user emailcustomer9@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedtrue
  • And 1 to 2 approved item reservations with following properties exists:
    user emailcustomer9@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedfalse
  • And today is "#{Time.now - rand(1..7).days}"
  • And 3 to 5 approved item reservations with following properties exists:
    user emailcustomer1@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
  • And 1 to 1 approved item reservations with following properties exists:
    user emailcustomer1@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
    model nameMacBook Air
  • And today is back to initial random date
  • And today is "#{Time.now - rand(3..5).months}"
  • And 1 to 1 approved item reservations with following properties exists:
    user emailcustomer1@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedtrue
    itemair123
    model nameMacBook Air
    purposeErsatzstativ für die Ausstellung.
  • And this contract is signed by "pius@zhdk.ch"
  • And this contract is closed on "#{Date.today}" by "pius@zhdk.ch"
  • And today is back to initial random date
  • And 1 to 1 approved item reservations with following properties exists:
    user emailcustomer8@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedtrue
  • And 1 to 1 more approved option reservations with following properties exists:
    user emailcustomer8@zhdk.ch
    inventory pool nameA-Ausleihe
    quantity2
  • And this contract is signed by "pius@zhdk.ch"
  • And 1 to 1 approved option reservations with following properties exists:
    user emailpeter@silie.com
    inventory pool nameA-Ausleihe
    inventory codesandsack123
    quantity2
    start date#{Date.yesterday}
    end date#{Date.today}
  • And 1 to 1 more approved option reservations with following properties exists:
    user emailpeter@silie.com
    inventory pool nameA-Ausleihe
    inventory codesandsack123
    quantity1
    start date#{Date.yesterday}
    end date#{Date.today + 1.month}
  • And this contract is signed by "pius@zhdk.ch"
  • And 1 to 1 approved license reservations with following properties exists:
    inventory pool nameA-Ausleihe
    assignedtrue
  • And this contract is signed by "pius@zhdk.ch"
  • And today is "#{Time.now - 5.days}"
  • And 1 to 1 approved item reservations with following properties exists:
    inventory pool nameIT-Ausleihe
    start date#{Date.today}
    end date#{Date.today + 4.days}
  • And 1 to 1 approved option reservations with following properties exists:
    inventory pool nameIT-Ausleihe
    start date#{Date.today}
    end date#{Date.today + 4.days}
  • And today is back to initial random date
  • And 1 to 1 approved item reservations with following properties exists:
    inventory pool nameA-Ausleihe
    assignedtrue
    inventory codeminibeam56
  • And this contract is signed by "pius@zhdk.ch"
  • And this contract is closed on "#{Date.today}" by "pius@zhdk.ch"
  • And the item with inventory code "minibeam56" has now the following properties:
    retired#{Date.today}
    retired reason#{Faker::Lorem.sentence}
  • And 1 to 1 approved item reservations with following properties exists:
    inventory pool nameA-Ausleihe
    assignedtrue
    inventory codeminibeam78
  • And this contract is signed by "pius@zhdk.ch"
  • And this contract is closed on "#{Date.today}" by "pius@zhdk.ch"
  • And the item with inventory code "minibeam78" has now the following properties:
    inventory pool nameIT-Ausleihe
    owner nameIT-Ausleihe
  • And 1 to 1 approved item reservations with following properties exists:
    user emailcustomer7@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedtrue
  • And this contract is signed by "pius@zhdk.ch"
  • And this contract is closed on "#{Date.today}" by "pius@zhdk.ch"
  • And 1 to 1 approved item reservations with following properties exists:
    user emailcustomer7@zhdk.ch
    inventory pool nameA-Ausleihe
    model package nameKamera Set2
    itemin_stock
    assignedtrue
  • And this contract is signed by "pius@zhdk.ch"
  • And this contract is closed on "#{Date.today}" by "pius@zhdk.ch"
  • And the following access right is revoked:
    user emailcustomer7@zhdk.ch
    inventory pool nameA-Ausleihe
  • And 1 to 1 approved item reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
    model nameKamera Stativ 123
  • And 1 to 1 approved item reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeFür das zweite Austellungswochenende.
    model nameKamera Stativ 123
  • And 1 to 1 more approved item reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeFür das zweite Austellungswochenende.
    model nameSharp Beamer 123
  • And 1 to 1 approved item reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeFür das dritte Austellungswochenende.
    start date#{Date.today + 7.days}
    end date#{Date.today + 8.days}
    model nameKamera Stativ 123
  • And 3 to 3 approved item reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeFür die Abschlussarbeit.
    model nameSharp Beamer 123
  • And 3 to 3 approved item reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
    model nameKamera Nikon X12
  • And 3 to 3 more approved item reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
    model nameKamera Stativ 123
  • And 1 to 1 more approved option reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
    inventory codeakku-aa
    quantity5
  • And 1 to 1 approved license reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeBestellung mit Software
  • And 1 to 1 approved item reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeBestellung mit Gegenstand ohne Ort
    itemowned
    item locationnil
  • And 1 to 1 approved item reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedtrue
    purposeUm meine Abschlussarbeit zu fotografieren.
    start date#{Date.yesterday}
    end date#{Date.today}
    model nameKamera Nikon X12
    itemin_stock
  • And this contract is signed by "pius@zhdk.ch"
  • And today is "#{Time.now - 5.days}"
  • And 1 to 1 approved item reservations with following properties exists:
    user emaillisa@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedtrue
    purposeAls Ersatz.
    start date#{Date.today}
    end date#{Date.today + 4.days}
    model nameInspiron 7000
    itemin_stock
  • And 1 to 1 more approved option reservations with following properties exists:
    user emaillisa@zhdk.ch
    inventory pool nameA-Ausleihe
    quantity1
  • And this contract is signed by "pius@zhdk.ch"
  • And today is back to initial random date
  • And 1 to 1 approved item reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedtrue
    start date#{Date.yesterday}
    end date#{Date.today}
    itemowned
  • And this contract is signed by "pius@zhdk.ch"
  • And 2 to 2 approved item reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameIT-Ausleihe
    assignedtrue
    purposeUm meine Abschlussarbeit zu fotografieren.
    start date#{Date.yesterday}
    end date#{Date.today}
  • And this contract is signed by "pius@zhdk.ch"
  • And 1 to 1 of these item reservations is returned:
    returned date#{Date.today}
    returned to userpius@zhdk.ch
  • And 1 to 1 approved item reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameIT-Ausleihe
    assignedtrue
    purposeUm meine Abschlussarbeit zu fotografieren.
    start date#{Date.yesterday}
    end date#{Date.today}
    model nameSharp Beamer 123
    itemlic111
  • And 1 to 1 more approved item reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameIT-Ausleihe
    assignedtrue
    itembeam749
  • And this contract is signed by "pius@zhdk.ch"
  • And 1 to 1 approved license reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameIT-Ausleihe
    assignedtrue
    start date#{Date.yesterday}
    end date#{Date.today}
    itemowned
  • And this contract is signed by "pius@zhdk.ch"
  • And 1 to 1 approved license reservations with following properties exists:
    user emailnormin@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedtrue
    purposePaketausgabe
    start date#{Date.yesterday}
    end date#{Date.today}
    model package nameKamera Set
    itemin_stock
  • And this contract is signed by "pius@zhdk.ch"
  • And 1 to 1 approved item reservations with following properties exists:
    user emailpetra@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
    start date#{Date.yesterday - 1.day}
    end date#{Date.today + 1.day}
    model nameSharp Beamer 123
  • And 1 to 1 more approved item reservations with following properties exists:
    user emailpetra@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
    start date#{Date.yesterday - 1.day}
    end date#{Date.today + 1.day}
  • And 1 to 1 submitted item reservations with following properties exists:
    user emaillisa@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedfalse
    purposeGanz dringend benötigt für meine Abschlussarbeit.
    model nameThinkpad Carbon
    soft overbookingtrue
  • And 1 to 1 approved item reservations with following properties exists:
    user emailpetra@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedtrue
    purposeUm meine Abschlussarbeit zu fotografieren.
    start date#{Date.yesterday}
    end date#{Date.today}
    model nameSharp Beamer 123
    itemin_stock
  • And 1 to 1 more approved option reservations with following properties exists:
    user emailpetra@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeUm meine Abschlussarbeit zu fotografieren.
    inventory codeakku-aa
    start date#{Date.yesterday}
    end date#{Date.today}
  • And this contract is signed by "pius@zhdk.ch"
  • And 1 to 1 submitted item reservations with following properties exists:
    user emaillisa@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedfalse
    purposeFotoshooting (Kurs Fotografie).
    start date#{Date.today + 37.days}
    end date#{Date.today + 45.days}
    model nameKamera Nikon X12
  • And 1 to 1 submitted item reservations with following properties exists:
    user emaillisa@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedfalse
    purposeBrauche ich zwingend für meinen Kurs.
    start date#{Date.today + 52.days}
    end date#{Date.today + 55.days}
    model nameKamera Nikon X12
    real overbookingtrue
  • And 3 to 5 submitted item reservations with following properties exists:
    delegation nameDelegation 1
    delegated user emailmina@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedfalse
  • And 3 to 5 approved item reservations with following properties exists:
    delegation nameDelegation 1
    delegated user emailjulie@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedfalse
    start date#{Date.today}
  • And 3 to 5 approved item reservations with following properties exists:
    delegation nameDelegation 5
    delegated user emaildelegated1@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedtrue
    start date#{Date.today}
  • And 3 to 5 approved item reservations with following properties exists:
    delegation nameDelegation 1
    delegated user emailmina@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedtrue
    start date#{Date.today}
  • And this contract is signed by "pius@zhdk.ch"
  • And today is "#{Time.now - 5.days}"
  • And 3 to 5 approved item reservations with following properties exists:
    delegation nameDelegation 1
    delegated user emailmina@zhdk.ch
    inventory pool nameA-Ausleihe
    assignedtrue
    start date#{Date.today}
  • And this contract is signed by "pius@zhdk.ch"
  • And today is back to initial random date
  • And today is "#{Time.now - rand(1..7).days}"
  • And 3 to 5 rejected item reservations with following properties exists:
    user emailcustomer1@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
  • And 1 to 1 rejected item reservations with following properties exists:
    user emailcustomer1@zhdk.ch
    inventory pool nameA-Ausleihe
    purposeErsatzstativ für die Ausstellung.
    model nameMacBook Air
  • And today is back to initial random date
  • Then there are 18 contracts in total
  • And all unsubmitted contract reservations are available
  • Then there are 51 fields in total
  • Then the normal dump is generated

Scenario: Genarating Huge Dataset

@generating_personas

  • Given the normal dump is loaded
  • And each model has at least 300 items
  • And each model has at least 300 submitted reservations
  • And each model has at least 300 approved reservations
  • Then the huge dump is generated

Source: features/personas/generating_personas.feature at commit eb240d9e, Leihs (GPL license).