コード例 #1
0
    void Start()
    {
        inst = this;

        StartCoroutine(Pulse(dm[0].GetComponent<RectTransform>(), 0.6f));
        StartCoroutine(Pulse(dm[1].GetComponent<RectTransform>(), 0.3f));
        StartCoroutine(Pulse(dm[2].GetComponent<RectTransform>(), 0f));

        /*foreach (Image d in dm)
                {
                    d.GetComponent<RectTransform>().localScale = Vector2.zero;
                }*/
    }
コード例 #2
0
    void Start()
    {
        inst = this;

        StartCoroutine(Pulse(dm[0].GetComponent <RectTransform>(), 0.6f));
        StartCoroutine(Pulse(dm[1].GetComponent <RectTransform>(), 0.3f));
        StartCoroutine(Pulse(dm[2].GetComponent <RectTransform>(), 0f));



        /*foreach (Image d in dm)
         *      {
         *          d.GetComponent<RectTransform>().localScale = Vector2.zero;
         *      }*/
    }
コード例 #3
0
        public HandlersTestQueries()
        {
            // Create mock instance
            var LMockDbContext = new Mock <MainDbContext>();

            // Upload pre-fixed dummy data
            var LParkingDbSet      = DummyLoad.GetDummyParkingList().AsQueryable().BuildMockDbSet();
            var LParkingPlaceDbSet = DummyLoad.GetDummyParkingPlaces().AsQueryable().BuildMockDbSet();

            // Populate database tables with dummy data
            LMockDbContext.Setup(AMainDbContext => AMainDbContext.Parking).Returns(LParkingDbSet.Object);
            LMockDbContext.Setup(AMainDbContext => AMainDbContext.ParkingPlaces).Returns(LParkingPlaceDbSet.Object);

            // Create test instance with mocked dependencies
            FMainDbContext = LMockDbContext.Object;
        }
コード例 #4
0
        public HandlersTestCommands()
        {
            // Create mock instances
            FMockDbContext = new Mock <MainDbContext>();

            // Upload pre-fixed dummy data
            var LCommandDbSet      = DummyLoad.GetDummyCommands().AsQueryable().BuildMockDbSet();
            var LParkingDbSet      = DummyLoad.GetDummyParkingList().AsQueryable().BuildMockDbSet();
            var LParkingPlaceDbSet = DummyLoad.GetDummyParkingPlaces().AsQueryable().BuildMockDbSet();

            // Populate database tables with dummy data
            FMockDbContext.Setup(AMainDbContext => AMainDbContext.CommandStore).Returns(LCommandDbSet.Object);
            FMockDbContext.Setup(AMainDbContext => AMainDbContext.Parking).Returns(LParkingDbSet.Object);
            FMockDbContext.Setup(AMainDbContext => AMainDbContext.ParkingPlaces).Returns(LParkingPlaceDbSet.Object);

            // Create fake services
            FAuthentication = new FakeAuthentication();
            FCommands       = new FakeCommands();
        }
コード例 #5
0
        public AccountsTest()
        {
            // Create instances to mocked all dependencies
            FMockDbContext = new Mock <MainDbContext>();

            // Upload pre-fixed dummy data
            var LCountriesDbSet = DummyLoad.ReturnDummyCountries().AsQueryable().BuildMockDbSet();
            var LCitiesDbSet    = DummyLoad.ReturnDummyCities().AsQueryable().BuildMockDbSet();
            var LUsersDbSet     = DummyLoad.ReturnDummyUsers().AsQueryable().BuildMockDbSet();
            var LSigninHistory  = DummyLoad.ReturnSigninHistory().AsQueryable().BuildMockDbSet();

            // Populate database tables with dummy data
            FMockDbContext.Setup(AMainDbContext => AMainDbContext.Countries).Returns(LCountriesDbSet.Object);
            FMockDbContext.Setup(AMainDbContext => AMainDbContext.Cities).Returns(LCitiesDbSet.Object);
            FMockDbContext.Setup(AMainDbContext => AMainDbContext.Users).Returns(LUsersDbSet.Object);
            FMockDbContext.Setup(AMainDbContext => AMainDbContext.SigninHistory).Returns(LSigninHistory.Object);

            // Create test instance with mocked dependencies
            FAccounts = new Accounts(FMockDbContext.Object);
        }