mirror of
https://gitlab.com/openstapps/openstapps.git
synced 2026-01-07 22:12:53 +00:00
refactor: build system
This commit is contained in:
@@ -12,7 +12,14 @@
|
||||
* You should have received a copy of the GNU General Public License along with
|
||||
* this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
import {SCBulkAddRoute, SCBulkDoneRoute, SCDish, SCMessage, SCThingOriginType, SCThingType} from '@openstapps/core';
|
||||
import {
|
||||
SCBulkAddRoute,
|
||||
SCBulkDoneRoute,
|
||||
SCDish,
|
||||
SCMessage,
|
||||
SCThingOriginType,
|
||||
SCThingType,
|
||||
} from '@openstapps/core';
|
||||
import {expect} from 'chai';
|
||||
import chai from 'chai';
|
||||
import chaiAsPromised from 'chai-as-promised';
|
||||
@@ -55,9 +62,7 @@ export class BulkSpec {
|
||||
});
|
||||
|
||||
const dish: SCDish = {
|
||||
categories: [
|
||||
'main dish',
|
||||
],
|
||||
categories: ['main dish'],
|
||||
name: 'foobar',
|
||||
origin: {
|
||||
indexed: moment().format(),
|
||||
@@ -70,9 +75,13 @@ export class BulkSpec {
|
||||
|
||||
await bulk.add(dish);
|
||||
|
||||
expect(client.invokeRoute).to.have.been.first.called.with(bulkAddRoute, {
|
||||
UID: 'bar',
|
||||
}, dish);
|
||||
expect(client.invokeRoute).to.have.been.first.called.with(
|
||||
bulkAddRoute,
|
||||
{
|
||||
UID: 'bar',
|
||||
},
|
||||
dish,
|
||||
);
|
||||
}
|
||||
|
||||
@test
|
||||
@@ -86,12 +95,8 @@ export class BulkSpec {
|
||||
});
|
||||
|
||||
const message: SCMessage = {
|
||||
audiences: [
|
||||
'students',
|
||||
],
|
||||
categories: [
|
||||
'news'
|
||||
],
|
||||
audiences: ['students'],
|
||||
categories: ['news'],
|
||||
messageBody: 'Lorem ipsum.',
|
||||
name: 'foobar',
|
||||
origin: {
|
||||
|
||||
Reference in New Issue
Block a user