mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-19 07:37:25 +01:00
fix(misc): Tweaks
* Updates the text shown for Mystic Hourglasses in the inventory to account for new features. * Fixes the date range for the Fall Festival to correctly start September 21. * Updates test for the Inventory Controller to use lodash for object key iteration.
This commit is contained in:
@@ -229,17 +229,17 @@ describe('Inventory Controller', function() {
|
||||
});
|
||||
|
||||
it('returns true if there are no items left to purchase', inject(function(Content) {
|
||||
for (var item in Content.gear.flat) {
|
||||
_.forEach(Content.gear.flat, function(v,item) {
|
||||
if (item.indexOf('mystery') > -1) {
|
||||
user.items.gear.owned[item] = true;
|
||||
}
|
||||
}
|
||||
for (var pet in Content.timeTravelStable.pets) {
|
||||
});
|
||||
_.forEach(Content.timeTravelStable.pets, function(v,pet) {
|
||||
user.items.pets[pet] = 5;
|
||||
}
|
||||
for (var mount in Content.timeTravelStable.mounts) {
|
||||
});
|
||||
_.forEach(Content.timeTravelStable.mounts, function(v,mount) {
|
||||
user.items.mounts[mount] = true;
|
||||
}
|
||||
});
|
||||
|
||||
expect(scope.hasAllTimeTravelerItems()).to.eql(true);
|
||||
}));
|
||||
@@ -251,11 +251,11 @@ describe('Inventory Controller', function() {
|
||||
});
|
||||
|
||||
it('returns true for Mystery Sets if there are no sets left to purchase', inject(function(Content) {
|
||||
for (var item in Content.gear.flat) {
|
||||
_.forEach(Content.gear.flat, function(v,item) {
|
||||
if (item.indexOf('mystery') > -1) {
|
||||
user.items.gear.owned[item] = true;
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
expect(scope.hasAllTimeTravelerItemsOfType('mystery')).to.eql(true);
|
||||
}));
|
||||
@@ -265,9 +265,9 @@ describe('Inventory Controller', function() {
|
||||
});
|
||||
|
||||
it('returns true for pets if user owns all pets in the Time Travel Stable', inject(function(Content) {
|
||||
for (var pet in Content.timeTravelStable.pets) {
|
||||
_.forEach(Content.timeTravelStable.pets, function(v,pet) {
|
||||
user.items.pets[pet] = 5;
|
||||
}
|
||||
});
|
||||
|
||||
expect(scope.hasAllTimeTravelerItemsOfType('pets')).to.eql(true);
|
||||
}));
|
||||
@@ -277,9 +277,9 @@ describe('Inventory Controller', function() {
|
||||
});
|
||||
|
||||
it('returns true for mounts if user owns all mounts in the Time Travel Stable', inject(function(Content) {
|
||||
for (var mount in Content.timeTravelStable.mounts) {
|
||||
_.forEach(Content.timeTravelStable.mounts, function(v,mount) {
|
||||
user.items.mounts[mount] = true;
|
||||
}
|
||||
});
|
||||
|
||||
expect(scope.hasAllTimeTravelerItemsOfType('mounts')).to.eql(true);
|
||||
}));
|
||||
|
||||
Reference in New Issue
Block a user