Skip to content

Commit

Permalink
Merge pull request #6 from Adamou02/pre-main
Browse files Browse the repository at this point in the history
fix: running workflow with an old version of node.js
  • Loading branch information
Adamou02 authored Jan 30, 2024
2 parents 1f0bec4 + 24b1905 commit f06a346
Show file tree
Hide file tree
Showing 9 changed files with 63 additions and 21 deletions.
2 changes: 1 addition & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ updates:
- package-ecosystem: "npm"
directory: "/"
schedule:
interval: "daily"
interval: "weekly"
labels:
- "npm dependencies"
reviewers:
Expand Down
9 changes: 5 additions & 4 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,17 +14,18 @@ jobs:

strategy:
matrix:
node-version: [16.x, 18.x]

node-version: [18.x]

steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- name: Run npm test
run: |
npm ci
npm run build --if-present
npm test
npm test
22 changes: 19 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
node_modules
packages
.angular
#Dossiers
.angular/
node_modules/
package/
dist/

#Fichiers

Check warning on line 7 in .gitignore

View workflow job for this annotation

GitHub Actions / spellcheck

Unknown word (Fichiers)
.angular-cli.json
*.log
*.iml

#Dossiers spécifiques à Visual Studio Code

Check warning on line 12 in .gitignore

View workflow job for this annotation

GitHub Actions / spellcheck

Unknown word (spécifiques)
.vscode/

#Fichiers spécifiques à macOS

Check warning on line 15 in .gitignore

View workflow job for this annotation

GitHub Actions / spellcheck

Unknown word (Fichiers)

Check warning on line 15 in .gitignore

View workflow job for this annotation

GitHub Actions / spellcheck

Unknown word (spécifiques)
.DS_Store

#Fichiers de configuration spécifiques à chaque utilisateur

Check warning on line 18 in .gitignore

View workflow job for this annotation

GitHub Actions / spellcheck

Unknown word (Fichiers)

Check warning on line 18 in .gitignore

View workflow job for this annotation

GitHub Actions / spellcheck

Unknown word (spécifiques)

Check warning on line 18 in .gitignore

View workflow job for this annotation

GitHub Actions / spellcheck

Unknown word (chaque)

Check warning on line 18 in .gitignore

View workflow job for this annotation

GitHub Actions / spellcheck

Unknown word (utilisateur)
.editorconfig
10 changes: 5 additions & 5 deletions angular.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,8 @@
"budgets": [
{
"type": "initial",
"maximumWarning": "500kb",
"maximumError": "1mb"
"maximumWarning": "2mb",
"maximumError": "4mb"
},
{
"type": "anyComponentStyle",
Expand All @@ -61,18 +61,18 @@
"builder": "@angular-devkit/build-angular:dev-server",
"configurations": {
"production": {
"browserTarget": "Genepropp:build:production"
"buildTarget": "Genepropp:build:production"
},
"development": {
"browserTarget": "Genepropp:build:development"
"buildTarget": "Genepropp:build:development"
}
},
"defaultConfiguration": "development"
},
"extract-i18n": {
"builder": "@angular-devkit/build-angular:extract-i18n",
"options": {
"browserTarget": "Genepropp:build"
"buildTarget": "Genepropp:build"
}
},
"test": {
Expand Down
20 changes: 20 additions & 0 deletions karma.conf.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
// karma.conf.js
module.exports = function(config) {
config.set({
frameworks: ['jasmine', '@angular-devkit/build-angular'],
plugins: [
require('karma-jasmine'),
require('karma-chrome-launcher'),
require('@angular-devkit/build-angular/plugins/karma')
],
browsers: ['ChromeHeadless'], // Utilisez Chrome en mode sans tête
reporters: ['progress', 'kjhtml'],
port: 9876,
colors: true,
logLevel: config.LOG_INFO,
autoWatch: true,
singleRun: false,
restartOnFileChange: true
});
};

Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
import { ComponentFixture, TestBed } from '@angular/core/testing';

import { LinkedHashmapComponent } from './linked-hashmap.component';
import { LinkedHashMap } from './linked-hashmap.component';

describe('LinkedHashmapComponent', () => {
let component: LinkedHashmapComponent;
let fixture: ComponentFixture<LinkedHashmapComponent>;
describe('LinkedHashMap', () => {
let component: LinkedHashMap<string, number>;
let fixture: ComponentFixture<LinkedHashMap<string, number>>;

beforeEach(() => {
TestBed.configureTestingModule({
declarations: [LinkedHashmapComponent]
declarations: [LinkedHashMap]
});
fixture = TestBed.createComponent(LinkedHashmapComponent);
fixture = TestBed.createComponent<LinkedHashMap<string, number>>(LinkedHashMap);
component = fixture.componentInstance;
fixture.detectChanges();
});
Expand Down
2 changes: 2 additions & 0 deletions src/main.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
/// <reference types="@angular/localize" />

import { platformBrowserDynamic } from '@angular/platform-browser-dynamic';

import { AppModule } from './app/app.module';
Expand Down
4 changes: 3 additions & 1 deletion tsconfig.app.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
"extends": "./tsconfig.json",
"compilerOptions": {
"outDir": "./out-tsc/app",
"types": []
"types": [
"@angular/localize"
]
},
"files": [
"src/main.ts"
Expand Down
3 changes: 2 additions & 1 deletion tsconfig.spec.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@
"compilerOptions": {
"outDir": "./out-tsc/spec",
"types": [
"jasmine"
"jasmine",
"@angular/localize"
]
},
"include": [
Expand Down

0 comments on commit f06a346

Please sign in to comment.