name: Test consistency between Paper & Fabric
on: 
  pull_request:
    branches:
      - main
    paths: 
      - src/fabric/**
      - android/src/paper/java/com/facebook/react/viewmanagers/**
      - android/src/paper/java/com/horcrux/svg/**
jobs:
  check:
    runs-on: ubuntu-latest
    concurrency:
      group: check-archs-consistency-${{ github.ref }}
      cancel-in-progress: true
    steps:
      - name: checkout
        uses: actions/checkout@v4
      - name: Use Node.js 18
        uses: actions/setup-node@v4
        with:
          node-version: 18
          cache: 'yarn'
      - name: Install node dependencies
        run: yarn
      - name: Check Android Paper & Fabric generated interfaces consistency
        run: yarn check-archs-consistency
